DEV Community

Dmitriy Loburets
Dmitriy Loburets

Posted on

Cursor pagination: how to do and pitfalls

In this video I introduce you to pagination topic in the fist part and add some caveats from my experience in the second part. The second part is mostly about cursor pagination for unique fields.

Additional note: if you use cursor pagination with non-unique column then it also can increase complexity for the queries. The more pages you skip, the more complex the query become to execute. So, consider it and check if your DB is ready for expected loading in case of long lists. It's another reason to double think do you really need the pagination for the not unique columns. But if you do, see the video for details.

Top comments (0)