I ran the following query in the MySQL console:
INSERT INTO pixel_window
SELECT id
FROM pixels
WHERE pixel_id='type2'
ORDER BY id DESC
LIMIT 5;
And received:
Query OK, 5 rows affected, 1 warning (0.00 sec)
Records: 5 Duplicates: 0 Warnings: 0
mysql> SHOW WARNINGS\G
*************************** 1. row ***************************
Level: Note
Code: 1592
Message: Statement may not be safe to log in statement format.
1 row in set (0.00 sec)
I played around a bit with the request and found out that when I skipped, the LIMITwarning disappears.
What does this warning mean? Why is the LIMITproblem in this subquery?
source
share