You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'AND `ucm_type_id` = AND `sha1_hash` = '' LIMIT 0, 1' at line 3 SQL=SELECT * FROM `sa34_ucm_history` WHERE `ucm_item_id` = AND `ucm_type_id` = AND `sha1_hash` = '' LIMIT 0, 1
No error after this patch.
Same approach can be applied to ContenthistoryModelHistory::getListQuery()
NOTE: Such errors occurs when ucm_item_id or ucm_type_id is 0 or non-numeric string as they are unquoted literals.
- 24 Oct 2015
- Tested successfully