Hey, I'm using uuid as PK for my users table and I...
# orm-help
k
Hey, I'm using uuid as PK for my users table and I would like to use cursor based pagination. Is that possible with uuid or do I need to add another unique column that's incremental?
1
j
Hi Kenny, I suggest you to use auto increment if you want cursor base pagiantion. UUID I can say that it's possible but it's will not be good in long term because it cannot identify as sequential values.
because cursor base you have orderBy your cursor field
but you can create composite index like UUID with sequential values(eg. createdAt, updatedAt)
I hope my answer is help you