Apparently the mysql does not allow update multiple tables to use order limit, but I need the update only be limited to a single row, how could I do it?
mysql> update t1, t2 set t1.lastContact = 1549706102, t2.timestamp = 1549706102, t2.data = 9 where t1.id = t2.parentId and t1.id = 378 and t2.timestamp > 1549706000 order by t1.id desc limit 1;
ERROR 1221 (HY000): Incorrect usage of UPDATE and ORDER BY
Thank you.
mysql> update t1, t2 set t1.lastContact = 1549706102, t2.timestamp = 1549706102, t2.data = 9 where t1.id = t2.parentId and t1.id = 378 and t2.timestamp > 1549706000 order by t1.id desc limit 1;
ERROR 1221 (HY000): Incorrect usage of UPDATE and ORDER BY
Thank you.