My frontend app can list of my items order by createdAt (for sure by calling API):
SELECT * FROM items ORDER BY createdAt
Output is for example:
id: myIdAAA
id: myIdEEE
id: myIdPPP
id: myIdRRR
Id of each item is UUID (there in example just myId*).
I can open detail of item by url /item/detail/myIdPPP and on this detail I have GO TO NEXT item.
The problem is, that I don`t know how to create SQL query to select next item like this:
SELECT * FROM items AFTER myIdEEE ORDER BY createdAt
Should return myIdPPP.
SELECT * FROM items AFTER myIdPPP ORDER BY createdAt
Should return myIdRRR.
It is possible and how?