It's true. The various LIMIT n DELETEs added to avoid locking for too long, they don't work everywhere. This appears to be due to a compilation option in SQLite, not tied to any particular version. So we have to do
DELETE FROM tbl WHERE what<ever LIMIT 10
as this, which works.
DELETE FROM tbl WHERE pk IN (SELECT pk FROM tbl WHERE what<ever LIMIT 10)
Fixed. Some SQLite versions accept those LIMIT clauses on DELETE (and UPDATE) and others don't. So this code no longer relies on the presence of the feature.
@wabetainfo reported: (https://wordpress.org/support/topic/sqlite_remove_expired-near-limit-syntax-error-1/)
It's true. The various LIMIT n DELETEs added to avoid locking for too long, they don't work everywhere. This appears to be due to a compilation option in SQLite, not tied to any particular version. So we have to do
as this, which works.