Which one comes first when MySQL processes the query?
An example:
SELECT pageRegions FROM pageRegions WHERE(pageID=?) AND(published=true) AND (publis
The limit is always applied at the end of result gathering, therefore after order by.
limit
order by
Given all your clauses, the order of processing will be
So you will get the closest record <= publishedOn matching all the conditions in the WHERE clause.