I wonder if there is a way to accomplish:
SELECT * FROM table
by using LIMIT and OFFSET like so:
LIMIT
OFFSET
Maybe not the cleanest solution but setting limit to a very high number could work. Offset needs to be 0.
Why not use a IF statement where you add the limit and offset to the query as a statement is true?
IF