March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
Hello PBI community. I am trying to make a date scheuler meausre based off of what customers are entitled to.
For example - if the customer is entitled to 2 birs - dateadd 6 months and if the customer is entitled to 3 birs then dateadd 4 months.
I am pushing out the Due Date for the customers by such increments and I have set a MAX bir entitlement for the customers as some customers may be entitled to 2 or 3 depending on history , I am basing the push out by their MAX entitlement. For some reason I am constantatly getting errors. I have attached my DAX forumla I am trying, any help ? Thanks in advance.
Please provide sanitized sample data that fully covers your issue. If you paste the data into a table in your post or use one of the file services it will be easier to assist you. Avoid posting screenshots of your source data if possible.
Please show the expected outcome based on the sample data you provided. Screenshots of the expected outcome are ok.
https://community.powerbi.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523
Sample data will look like this:
Customer Name | Seats | BIR Range | BIR Due Date | BIR Entitlement |
A | 300 | 250-999 | 06/02/2022 | 2 |
B | 1500 | 1000 or more | 08/08/2022 | 3 |
C | 270 | 250-999 | 12/31/2022 | 2 |
Sample outcome should be this: Logic
Customers entitled to 2 BIR's recieve a BIR EVERY 6 MONTHS , Customers with 3 BIRs are entitled to one every 4 months. The date should be pushed out in a cadence FROM the Due Date.
Customer Name | Seats | BIR Range | BIR Due Date | BIR Entitlement | Next BIR Date |
A | 300 | 250-999 | 06/02/2022 | 2 | 12/02/2022 |
B | 1500 | 1000 or more | 08/08/2022 | 3 | 12/08/2022 |
C | 270 | 250-999 | 12/28/2022 | 2 | 06/28/2022 |
Hi,
This calculated column formula work
=if(Data[BIR Entitlement]=2,EDATE(Data[BIR Due Date],6),EDATE(Data[BIR Due Date],4))
Hope this helps.
Hi, @tyannamorrison
You can try the following methods.
Next BIR Date =
IF (
[BIR Entitlement] = 2,
IF (
MONTH ( [BIR Due Date] ) > 6,
DATE ( YEAR ( [BIR Due Date] ) + 1, MONTH ( [BIR Due Date] ) + 6 - 12, DAY ( [BIR Due Date] ) ),
DATE ( YEAR ( [BIR Due Date] ), MONTH ( [BIR Due Date] ) + 6, DAY ( [BIR Due Date] ) )
),
IF (
[BIR Entitlement] = 3,
IF (
MONTH ( [BIR Due Date] ) > 8,
DATE ( YEAR ( [BIR Due Date] ) + 1, MONTH ( [BIR Due Date] ) + 4 - 12, DAY ( [BIR Due Date] ) ),
DATE ( YEAR ( [BIR Due Date] ), MONTH ( [BIR Due Date] ) + 4, DAY ( [BIR Due Date] ) )
)
)
)
Is this the result you expect?
Best Regards,
Community Support Team _Charlotte
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Thank you so much for this solution, there were no syntax errors and ran smoothly. Unfortenatly when I added it to the visual I ran into an error. Both measures that are being used is a date type column(MAX Due Date) and for some odd reason the measure (MAX BIR) only has the format option of text - would this cause the issue I am facing?
Hi, @tyannamorrison
You can check the following blog and choose a way to pass your files.
How to provide sample data in the Power BI Forum - Microsoft Power BI Community
Best Regards,
Community Support Team _Charlotte
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi, @tyannamorrison
Are you able to provide PBIX files for testing? Sensitive information can be removed in advance. With this error report screenshot alone, it is not possible to directly determine the cause of the error.
Best Regards,
Community Support Team _Charlotte
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
124 | |
89 | |
84 | |
70 | |
51 |
User | Count |
---|---|
206 | |
146 | |
97 | |
79 | |
69 |