Run Code  | API  | Code Wall  | Users  | Misc  | Feedback  | Login  | Theme  | Privacy  | Patreon 

SFS_WindowFunctions

Language: Layout:
View schema
Execution time: 0,02 sec, rows selected: 27, rows affected: 9, absolute service time: 0,2 sec, absolute service time: 0,19 sec 
fork mode |  history
   ORDERID CUSTID VAL ORDERDATE
1 10782 12 18 01.01.2017 00:00:00
2 10807 12 23 01.01.2016 00:00:00
3 10586 12 28 01.01.2018 00:00:00
4 10767 28 30 01.02.2017 00:00:00
5 10898 28 33 01.02.2016 00:00:00
6 10900 28 36 01.02.2018 00:00:00
7 10883 36 36 01.03.2017 00:00:00
8 11051 36 40 01.03.2016 00:00:00
9 10815 36 45 01.03.2018 00:00:00
   CUSTID ORDERID VAL PREVVAL NEXTVAL
1 12 10807 23 NULL 18
2 12 10782 18 23 28
3 12 10586 28 18 NULL
4 28 10898 33 NULL 30
5 28 10767 30 33 36
6 28 10900 36 30 NULL
7 36 11051 40 NULL 36
8 36 10883 36 40 45
9 36 10815 45 36 NULL
   ROWNUM RANK DENSE_RANK NTILE VAL
1 1 1 1 1 18
2 2 2 2 1 23
3 3 3 3 2 28
4 4 4 4 2 30
5 5 5 5 3 33
6 6 6 6 3 36
7 7 6 6 4 36
8 8 8 7 4 40
9 9 9 8 5 45