Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
How can I generate a column to display the difference between two rows?
date |
1/17/2019 |
1/17/2019 |
1/20/2019 |
1/20/2019 |
1/21/2019 |
1/21/2019 |
1/21/2019 |
1/21/2019 |
1/21/2019 |
1/21/2019 |
1/21/2019 |
1/21/2019 |
1/22/2019 |
1/22/2019 |
1/22/2019 |
1/22/2019 |
1/22/2019 |
1/22/2019 |
1/22/2019 |
1/23/2019 |
1/23/2019 |
1/23/2019 |
1/23/2019 |
1/24/2019 |
1/24/2019 |
1/24/2019 |
1/24/2019 |
1/24/2019 |
1/24/2019 |
1/24/2019 |
1/24/2019 |
1/25/2019 |
1/25/2019 |
Assuming date is a numeric date field:
LOAD date, if(RowNo() <> 1, date - previous(date)) as diff ....