This is easily translatable into fauna (assuming $LIMIT < 100k
): Drop(Paginate(....., {size: $LIMIT}), $OFFSET)
. “But, Ben!” I hear you exclaim: “isn’t that really inefficient?”. Yes it is, and so is the SQL. What you probably want to do is keyset pagination, which is efficient, and also representable in fauna using the Range
function, or using the before
and after
cursors.
3 Likes