Answer the question
In order to leave comments, you need to log in
How to make a request with pagination if there is a hasMany link?
In Oracle, you need to think of a query that would give the following result:
ID | RN wrong: row_number() over ( partition by id order by id ) | RN needs: |
---|---|---|
one | one | one |
one | 2 | one |
one | 3 | one |
5 | one | 2 |
5 | 2 | 2 |
eight | one | 3 |
eight | 2 | 3 |
12 | 2 | 4 |
Answer the question
In order to leave comments, you need to log in
What you probably want is a subquery grouped by id and row_number() and then a join to the original table.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question