Forum Discussion
How to add a date parameter column to a query
So here is an exmaple of some of my Data. I have a Due_date Column. I need to be able to have a variable parameter that allows me to change the # of days AFTER the due_date. Once I have this 'X' Days after Due Date Variable, I need to be able connect that date to my date column. I need to try to show what 'Week' that 'X' Days after Due Date Variable falls into and make my visuals based on that data. But I am unable to due that right now because I have a DAX Measure calculating the date after due date based on my parameter.
- jkdt332 years agoNew Member
- Anonymous2 years agoNot applicable
Hi jkdt33 ,
Below is my table:
The following DAX might work for you:
X days after due date = var dat = SELECTEDVALUE('Table'[Due_Date]) return dat+'Days after due date'[Days after due date Value]The final output is shown in the following figure:
Best Regards,
Xianda Tang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- jkdt332 years agoNew Member
Ill try to re explain my needs better to better understand the entirety of what I am looking for and needing.
I have 2 total tables. An accounting fact table and a Date table.
Accounting Fact Table
- I have a column that has a outstanding balance
- I have a Colmn that has the original Due_Date for that balance
- My Task is i need to have a variable/parameter day to be able to change how many ('X') days is past the original due date. So we want to know when is 90 days, 150 days, 200 days, etc. past the due date
- I need to have this 'Variable Date' to be in a column so that I can use this column to be my relationship date with my Date Table
- I need to create my visuals based on the Date of the variable date column.