4 ms·
Do Not Use Offset for pagination (2014)
- bananabiscuit 6y agoDon’t agree. The alternative suggested is much more complicated. In real life very few people go deep into the further pages of a table, so offset is just fine most of the time, so just do that and only do the more complicated thing if it becomes obvious that you need to (probably never).
- erik_seaberg 6y agoIt’s worth avoiding because it’ll start causing problems for your biggest customers first with no warning, and user-facing timeouts provoke users to heavily retry exactly those shard-crushing queries you most wish they wouldn’t.