You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'in-putxet-gotmar and session_id = "o61q3gquht2cckm6k8kf7nkok6"' at line 1: SELECT * FROM reservas WHERE propiedad_fk = villa-in-putxet-gotmar and session_id = "o61q3gquht2cckm6k8kf7nkok6"