Query Error in 'CPSetSelection::execute' method in '/var/www/vhosts/' on line 6583, 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 ') ORDER BY mainTable.cpda_seq, mainTable.cpda_id' at line 1

Full query: SELECT mainTable.cpda_id FROM cp_data AS mainTable LEFT OUTER JOIN cp_data AS table0 ON table0.cpda_meta_id = mainTable.cpda_id AND table0.cpda_meta_key = '414' WHERE mainTable.cpda_meta_id = 365 AND mainTable.cpda_meta_key = 'set_element_stub' AND mainTable.cpda_active = 1 AND mainTable.cpda_id IN(390,398,1628,1689,960,916,931,1185,1933,) ORDER BY mainTable.cpda_seq, mainTable.cpda_id