DB Error: ERROR: invalid input syntax for integer: "consulta" LINE 1: SELECT * FROM galerias WHERE id = 'consulta' AND estado = 1 ^