I have some data that I'd like to convert the weekly amounts to monthly amounts that the amounts actually were earned within that month. I'm able to convert the weekly amounts to monthly amounts by taking the DateTimeMonth for the start of the week but that becomes hard for certain weeks that are in two months. See Example below:
| Salesperson | Week Date | Revenue |
| Joe | 1/1/2023 | 3000 |
| Joe | 1/8/2023 | 2000 |
| Joe | 1/15/2023 | 4000 |
| Joe | 1/22/2023 | 6000 |
| Joe | 1/29/2023 | 5000 |
| Joe | 2/5/2023 | 1000 |
Technically revenue for January should be: (3000+2000+4000+6000+3000=18,000). But if I use the DateTimeMonth and then cross tab it, the January amount becomes 20,000. How do I go about fixing this?