how do i create a conditional limit in a select query?

select * from (
    Select * from table_name
    ORDER BY date_column LIMIT 2
 ) as foo ORDER BY date_column DESC LIMIT 1

CLICK HERE to find out more related problems solutions.

Leave a Comment

Your email address will not be published.

Scroll to Top