Forum Discussion
Modification of DAX for Aging Calculation Based on Selected Month
Hi DataNinja777 - Thank you for helping and looking into this.
For point 1, I didn’t realize that the 'Calendar Ultimate' table doesn't cover the entire period. I will correct this now.
For point 2, my data originally looks like the example below, but in the data I shared with you, I have only provided the Due Amount (Balance).
| Customer_Code | Inv_Nbr | Inv_Date | Inv_Amt | Paid_Amt | Due_Amount | Submission_Date | Due_Date |
| 123456 | 12324 | 1-Jul-23 | 2510 | 2,510 | - | 01-Aug-23 | 01-Oct-23 |
| 126001 | 32313 | 2-Jul-23 | 2860 | 2,860 | - | 17-Aug-23 | 17-Aug-23 |
| 123456 | 21212 | 1-Jul-23 | 2510 | - | 2,510 | 01-Aug-23 | 01-Oct-23 |
| 126001 | 1212 | 2-Jul-23 | 2860 | - | 2,860 | 17-Aug-23 | 17-Aug-23 |
Hi InsightSeeker ,
OK. The picture is now clearer. In order to get a information as to the aging of the accounts receivale at any particular point in time, you need to utilize the invocie amount, invocie date, and paid amount and paid date fields instead of the due amount column, which is dependent on particualr date status. If we just base our analysis on the [Due_Amount] column, our analysis will be restricted to the due amount as of the date the data was extracted, and we cannot perform flexible analysis for multiple periods because that fact table figures you provided are only providing the status of the AR as of the particular date which the data was downloaded. So, in order to perform the correct analysis over multiple periods instead of just as of the date the data was extracted, we also need to utilize Invoice amount and Paid amount rather than just Due_Amount information.
Best regards,