Database Error; SQL: SELECT
DISTINCT
`t`.`ID`, `t`.`post_title`, `t`.`post_type`, `t`.`menu_order`, `t`.`post_date`
FROM `wp_ychtposts` AS `t`
LEFT JOIN `wp_ychtpodsrel` AS `rel_company_user` ON
`rel_company_user`.`field_id` = 1425
AND `rel_company_user`.`item_id` = `t`.`ID`
LEFT JOIN `wp_ychtusers` AS `company_user` ON
`company_user`.`ID` = `rel_company_user`.`related_item_id`
LEFT JOIN `wp_ychtpods_company` AS `d` ON `d`.`id` = `t`.`ID`
WHERE ( ( `company_user`.`ID` = ) AND ( `t`.`post_type` = 'company' ) AND ( `t`.`post_status` IN ( 'publish' ) ) )
ORDER BY `t`.`menu_order`, `t`.`post_title`, `t`.`post_date`; Response: 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 ') AND ( `t`.`post_type` = 'company' ) AND ( `t`.`post_status` IN ( 'publish' ...' at line 15