I have a script that is pulling data from a server everyday. It has a date column from August-present. How can I get which data is from 2 Quarters or 3 Months or 4 Weeks or 10 Days starting from the present day from the data? This calculations should be in separated columns like. And I think a flag will be needed? And is it possible to continuously calculate this using the latest added date?
I'm not sure what is the easiest method for this but this is my example
Date | 2 Quarter | 3 Months | 4 Weeks | 10 Days |
12-01-2024 | 0 | 1 | 0 | 0 |
12-02-2024 | 0 | 1 | 0 | 0 |
12-03-2024 | 0 | 1 | 0 | 0 |
12-04-2024 | 0 | 1 | 0 | 0 |
12-05-2024 | 0 | 1 | 0 | 0 |
12-06-2024 | 0 | 1 | 0 | 0 |
... | 0 | 1 | 0 | 0 |
02-01-2024 | 0 | 1 | 1 | 0 |
02-02-2024 | 0 | 1 | 1 | 0 |
02-03-2024 | 0 | 1 | 1 | 0 |
.... | 0 | 1 | 1 | 1 |
03-01-2024 | 0 | 1 | 1 | 1 |
03-02-2024 | 0 | 1 | 1 | 1 |
03-03-2024 | 0 | 1 | 1 | 1 |
03-04-2024 | 0 | 1 | 1 | 1 |
03-05-2024 | 0 | 1 | 1 | 1 |
03-06-2024 | 0 | 1 | 1 | 1 |