Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Ber001
Regular Visitor

DAX function with conditions

Dear,

 

I'm getting crazy by trying to do the fonction below for a couple of days...

 

I have to tables :

The first one : A date table 1 with a column 1 including the first day of each month

The seconde one : A Budget table 2 with multiple columns but the 3 concenred on are : Estimated Revenue, Date IN, Date OUT.

 

On top of that I have a table and a chart with the real revenue (vertical axis) and the months (Horizontal axis)

My goal is to add a "budget line" on this chart but the budget change month by month.

So would like to have a calculated column (in the Data table) or a mesure to have the sum of the "budget revenu" month by month.

 

I tried a mesure : SMUX (Table 2; IF (AND (RELATED('Table1'[Column1]) >= [Date IN]; RELATED('Table1'[Column1]) <= [Date OUT]); [Estimated Revnue]))

 

But impossible to show this in a shart combined with month by month view...

 

I've tried a lot of other things but anything works... Maybe will I have to do this with Power Query but I have to use data in 2 different tables...

 

Thank you for your help.
Bertrand

 

 

 

1 REPLY 1
daxer-almighty
Solution Sage
Solution Sage

This seems to be a typical budgeting/forecasting scenario. Please take a look at this pattern: https://www.daxpatterns.com/budget/

 

Use www.daxpatterns.com to find any other patterns.

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

Find out what's new and trending in the Fabric community.

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.