The ultimate Microsoft Fabric, Power BI, Azure AI, and SQL learning event: Join us in Stockholm, September 24-27, 2024.
Save €200 with code MSCUST on top of early bird pricing!
Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started
Hi friends,
I am still new to Power BI, hope you guys can provide me some guidance. Here is my situation:
I would like to pick min date for each level of percentile (low, mid, and high) from each provider separately based on the condition that the percentage in PctAvailable column is greater than the corresponding percentage in slicer (on the leftside of the screenshot below). I created three columns, LowDate, MidDate, and HightDate to store the calculated min dates. Also, I added columns LowPCT, MidPCT, and HighPCT to show the selected percents from slicers for demenstration purposes. Using provider 403 as example, the LowDate is 10/13, MidDate is 12/20, and HighDate is also 12/20 based on the current selections. However, the min dates of each level don't change when different values are selected. It looks like the min dates are selected using the min percentage of each level, not dynamically update based on the selection.
I created three tables containing the values of each slicer, called LowSelection, MidSelection, and HighSelection.
Here are the formulas that I used for the calculation (using Low percentile calcs as example)
LowPCT= if(HASONEFILTER(LowSelection[Low]),LOOKUPVALUE(LowSelection[Low],LowSelection[Low],values(LowSelection[Low])))
LowDate=
@Yin34 Correct, calculated columns are not dynamic based upon user input. You would need a measure like:
LowDate =
VAR __LowPCT = [LowPCT]
RETURN
CALCULATE(MIN('Table'[SlotDatetimeDTS]),FILTER(ALL('Table'),'Table'[PctAvailable]>__LowPCT))
Hi Greg @Greg_Deckler
Thanks for the reply!
For the measure you proposed, is there a way to add the condition for ProviderID? Because I would like to pick the min date for each provider separately. Like in the screenshot, the LowDate for provider 403 is 10/13, but the min date for other providers could be different if his/her min SlotDateTimeDTS with PctAvailable >10% is not 10/13. It looks like your formula pick the overall min date across all the providers.
Thank you so much!
Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.
Check out the August 2024 Power BI update to learn about new features.
User | Count |
---|---|
21 | |
19 | |
18 | |
18 | |
14 |
User | Count |
---|---|
36 | |
35 | |
20 | |
20 | |
17 |