The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
I have this formula:
YTD Budget = VAR MaxMonth = [MaxMonth]
RETURN CALCULATE([CustomerBudget],'Date'[MonthNum] <= MaxMonth)
It works but it's showing YTD Budget (same number) for every month.
How do I hide all the future months and only show in this case January. So similar how Yago YTD is showing up.
Thank you for your help!!!
Solved! Go to Solution.
Probably the budget is not blank then, perhaps check if the sales column is blank?
Your formula would be:
YTD Budget (final) = VAR MaxMonth = [MaxMonth]
RETURN IF(NOT(ISBLANK([Sales])),
CALCULATE([CustomerBudget],'Date'[MonthNum] <= MaxMonth), blank())
Proud to be a Super User!
Awesome Keyboard Shortcusts in Power BI, thumbs up if you like the article
My Community Blog Articles (check them out!)
My Blog - Power M code to automatically detect column types -
How to create test data using DAX!
YES!!! This formula worked:
Hi,
IF(NOT(ISBLANK([CustomerBudget] ), CALCULATE([CustomerBudget],'Date'[MonthNum] <= MaxMonth), BLANK())
Proud to be a Super User!
Awesome Keyboard Shortcusts in Power BI, thumbs up if you like the article
My Community Blog Articles (check them out!)
My Blog - Power M code to automatically detect column types -
How to create test data using DAX!
Thank you so much, Steve, but something is not working:
You would still need the var.
YTD Budget = VAR MaxMonth = [MaxMonth]
RETURN
if(not(blank([CustomerBudget]),
CALCULATE([CustomerBudget],'Date'[MonthNum] <= MaxMonth), blank())
Proud to be a Super User!
Awesome Keyboard Shortcusts in Power BI, thumbs up if you like the article
My Community Blog Articles (check them out!)
My Blog - Power M code to automatically detect column types -
How to create test data using DAX!
Probably the budget is not blank then, perhaps check if the sales column is blank?
Your formula would be:
YTD Budget (final) = VAR MaxMonth = [MaxMonth]
RETURN IF(NOT(ISBLANK([Sales])),
CALCULATE([CustomerBudget],'Date'[MonthNum] <= MaxMonth), blank())
Proud to be a Super User!
Awesome Keyboard Shortcusts in Power BI, thumbs up if you like the article
My Community Blog Articles (check them out!)
My Blog - Power M code to automatically detect column types -
How to create test data using DAX!
YES!!! This formula worked:
Welcome! Don't forget to mark as solution.
Proud to be a Super User!
Awesome Keyboard Shortcusts in Power BI, thumbs up if you like the article
My Community Blog Articles (check them out!)
My Blog - Power M code to automatically detect column types -
How to create test data using DAX!
User | Count |
---|---|
11 | |
8 | |
6 | |
6 | |
6 |
User | Count |
---|---|
24 | |
14 | |
13 | |
10 | |
7 |