I have the following table
| Date | SKUs |
|---|---|
| 2022-02-01 | A, B, C |
| 2022-02-02 | B, C, D |
| 2022-02-03 | C, D, E |
| 2022-02-04 | C, D |
| 2022-02-05 | G, H |
Now I need to find the difference b/w SKUs of current date with previous date (something like lag function in Postgres)
| Date | SKUs | SKU Diff |
|---|---|---|
| 2022-02-01 | A, B, C | |
| 2022-02-02 | B, C, D | D |
| 2022-02-03 | C, D, E | E |
| 2022-02-04 | C, D | |
| 2022-02-05 | G, H | G, H |
SKUs column is of array type