Postgresql Cannot Cast Type Boolean To Character