The Use The Index Luke material about this is essential background reading, but in terms of actually implementing: My favorite SQL implementation of cursor-based keyset pagination can be found on this Hasura issue: https://github.com/hasura/graphql-engine/issues/141 , specifically this comment: https://github.com/hasura/graphql-engine/issues/141#issuecom... . Something so elegant about this SQL. I enjoy it a lot. Als…
> For row comparisons, (a, b) > (x, y) is equivalent to:
> (a > x) OR ((a = x) AND (b > y))
[1] https://dev.mysql.com/doc/refman/8.0/en/comparison-operators...