Ocurrió un error con la base de datos

Error Number: 1064

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 ') IS NULL AND `cfd`.`custom_fields_item_id` = '577'' at line 5

SELECT `cf`.`custom_fields_alias`, `custom_fields_type`, `cf`.`custom_fields_name_es`, `cfd`.`custom_fields_data_value_es`, `cfd`.`custom_fields_data_value2_es` FROM (`custom_fields_categories` cfc) LEFT JOIN `custom_fields` cf ON `cf`.`custom_fields_id` = `cfc`.`custom_fields_categories_custom_fields_id` LEFT JOIN `custom_fields_data` cfd ON `cfd`.`custom_fields_data_field_id` = `cf`.`custom_fields_id` WHERE () IS NULL AND `cfd`.`custom_fields_item_id` = '577'

Filename: /var/www/clients/client0/web231/web/models/custom_fields_model.php

Line Number: 224