Forum Discussion
Show days in month between two dates
Hi Everyone,
I have a table with a start date and end data for Employees/Trainees, and I would like to get the days that ressources are working for a company by month
So imagine, I have this kind of table:
| Name | Entry Date | Leave Date |
| Bob | 01/01/2022 | 15/03/2022 |
| Max | 01/02/2022 | 30/04/2022 |
And I would like to get something like that:
| Name | Entry Date | Leave Date | January | February | March | April |
| Bob | 01/01/2022 | 15/03/2022 | 31 | 28 | 15 | 0 |
| Max | 01/02/2022 | 30/04/2022 | 0 | 28 | 31 | 15 |
Any clues how can I achieve that?
Many thanks in adavance for your help
Cookistador - pls try this PBIX FILE,
We worked on the power query part and taken into account only April Month to keep it simple and to give you an idea on one way to approach your requirement. You can replicate the same logic for other months.
Let me know how you are going about it.
If this answered your question I would be happy if you could mark my post as a solution and give it a thumbs up
Best regards
Manoj Nair
Linkedin - https://www.linkedin.com/in/manoj-nair-%E2%98%81-344666104/
1 Reply
- Manoj_Nair
Solution Supplier
Cookistador - pls try this PBIX FILE,
We worked on the power query part and taken into account only April Month to keep it simple and to give you an idea on one way to approach your requirement. You can replicate the same logic for other months.
Let me know how you are going about it.
If this answered your question I would be happy if you could mark my post as a solution and give it a thumbs up
Best regards
Manoj Nair
Linkedin - https://www.linkedin.com/in/manoj-nair-%E2%98%81-344666104/