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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
Anand_Murthy
Frequent Visitor

Condition Column not giving the right values

Hello All,

 

I have revenue table which has a coImn for projected revenue and actual revenue,I'm trying to comeup with a line chart where I have only one line which would be solid till the current month ( Actual revenue) and dotted for the rest of the year( Projected).

 

For example : This would be for the Apr-Mar FY, April being my first monthI will have the actual revenue and it would be 0 for the remaining months. So my graph should show the April month actual revenue and for the remaining month it shoud show dotted line with projected revenue values.

 

I'm trying to do it as follows, any other suggestion will be helpful

- I 'm creating a condition column , which I will use to plot the graph 

     IF Monthly Revenue = 0 THEN Projected Revenue

     ELSE Monthly Revenue

The new column is giving me the right value for the future months, but for the current month I'm getting a different value 

In the table below "Revenue & Projection" column value for April should have been equal to "Monthly Revenue" value

MonthMonthly RevenueProj. RevRevenue & Projection
Apr6640173.41577545207205289.415
May072518047251804
Jun073885567388556
Jul073522207352220
Aug065806566580656
Sep067820046782004
Oct067353906735390
Nov063593406359340
Dec069442986944298
Jan061917666191766
Feb058890005889000
Mar067579986757998

 

 

 
1 ACCEPTED SOLUTION
Anonymous
Not applicable

To do something like this you have to have 2 lines in a chart. One will be the real revenue and the other will be the projected one. Then you'll be able to set the attributes of each line separately. With one line and one measure it's not achievable.

So, create 2 measures. One with the actual revenue and the other with a projection and put in one line chart. Customize both lines.

Best
D

View solution in original post

4 REPLIES 4
Anonymous
Not applicable

You should find something that suits your needs in the attached file.

 

Best

D

Anonymous
Not applicable

To do something like this you have to have 2 lines in a chart. One will be the real revenue and the other will be the projected one. Then you'll be able to set the attributes of each line separately. With one line and one measure it's not achievable.

So, create 2 measures. One with the actual revenue and the other with a projection and put in one line chart. Customize both lines.

Best
D
ash123
Regular Visitor

Hi Anand, 

 

Your approach to writing Dax was correct. I tried it by myself and found it working.

 

Result: 

 

Result_TableResult_Table

 

Dax: 

 

combined =
IF (
'Table'[Monthly Revenue] = 0,
'Table'[Proj. Rev],
'Table'[Monthly Revenue]
)

 

Final Visual:

trend_visualtrend_visual

Regards,

Kaushlendra Mishra

www.powerbitalks.com

Linkedin-www.linkedin.com/in/kaushlendra-mishra-49627310

deevaker
Resolver I
Resolver I

Hi Anand, Can you please share your dataset and DAX formula that you have written.

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.