Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
I need a DAX formula to add a number of days (leadtime) to a date, returning a new date. The added days is piced from a variable, so it is not a fixed number.
The needed function will be like this
"Original Date" + "# of days" returns "New Date"
Solved! Go to Solution.
Hi OHM
I would suggest creating a seperate table with the category in one column and additional days in the other. Provided this category is also in the orignial dataset you can link between your current table and this new table, creating a relationship between the category in each table.
Then you should be able to create a new column in your original table along the lines of:
Leadtime Deadline = [Original Date] + table2[additional days]
Having the second table means that if any of the variable additional days change you can simply update that table rather than updating the query/calculation. Best of luck
Hi OHM
I would suggest creating a seperate table with the category in one column and additional days in the other. Provided this category is also in the orignial dataset you can link between your current table and this new table, creating a relationship between the category in each table.
Then you should be able to create a new column in your original table along the lines of:
Leadtime Deadline = [Original Date] + table2[additional days]
Having the second table means that if any of the variable additional days change you can simply update that table rather than updating the query/calculation. Best of luck
User | Count |
---|---|
77 | |
74 | |
42 | |
32 | |
28 |
User | Count |
---|---|
99 | |
92 | |
50 | |
49 | |
46 |