I have this table:
ID | MONDAY | TUESDAY | WEDNESDAY | THURSDAY | FRIDAY | SATURDAY | SUNDAY |
5001 | 200 | 20 | 50 | 0 | 0 | 60 | 90 |
5002 | 300 | 40 | 50 | 20 | 25 | 65 | 10 |
5003 | 690 | 55 | 70 | 80 | 10 | 10 | 60 |
And I want to achieve this:
ID | Revenue | Period |
5001 | 420 | 08.14-06-2020 |
5002 | 510 | 08.14-06-2020 |
I only have the weekdays, but the values on the weekdays are always this weeks data.
So I need something that get's the current week and finds what's the date for Monday and Sunday for this week
For example :
Monday == 08
Sunday == 14
So that last column would have 08.14-06-2020
Does anyone have any ideas on this?
Solved! Go to Solution.
Hi soncoku,
I've attached my workflow for you to download if needed.
If this solves your issue please mark the answer as correct and also hit the like button, if not let me know!
Thanks,
Abhra Mitra
Hi, @soncoku
Try this.
Please mark as a solution + like, if it works for you.
I've offered a different treatment for your consideration
I feel that the current solutions offered might be problematic when:
1. your week crosses months
2. your months cross years
Therefore, I provided a 'Period' treatment that is optically different (it includes the running month + year).
If I'm way off, apologies.
Cheers!
The code of bhrmitra is working okay but only for the current week. (And that's fine) But I forgot to mention that sometimes I will need to go back for weekly reports.
For example I'll need a weekly report from the past 2 weeks.
I have a filter where I choose the range for a past week, from Monday to Sunday (always).
Now the code of the @bhrmitra always gives me the current week on the Period, even though I'm seeing the report of 2 weeks ago.
I've attached a picture for you to see.
So the idea is that if I choose a past week in the filter tool I want the last column to the dates of that week in the Period.
example (25.31-05-2020)
Hi soncoku,
I have used a Text Input tool for you to enter the custom date. Remember you have to provide this date even for this week as well.
If this solves your issue please mark the answer as correct and also hit the like button, if not let me know! I've attached my workflow for you to download if needed.
Thanks,
Abhra Mitra