cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Helper IV
Helper IV

IF statement in table using measures,

Hi Guys,

 

What I'm trying to do as a measure to work in a table and probably charts too.

 

=IF(Month >= Month(Today()), Year = Year(Today()), 'Show Measure with new calculated figures','show historic sales' (Sales)

 

So

 

Jun                    :    Jul                    :             Aug

 

10                     :   15                       :      20

 

Sales field         : Sales Field             :     Calculated measure.

 

Thanks  

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Helper IV
Helper IV

Re: IF statement in table using measures,

I gave up waiting and worked it out lol, just need to add the Year bit in, which i'll sort out easily.

 

Measure 3 = if([Measure 2]>= MONTH(TODAY()),[Measure 2],[Measure 4])

View solution in original post

2 REPLIES 2
Highlighted
Super User II
Super User II

Re: IF statement in table using measures,

 

Measure = 
IF([Month]>MONTH(TODAY()) && [Year]=YEAR(TODAY());
[Calculated measure];
[Historic sales]
)

 

 


Connect on LinkedIn
Highlighted
Helper IV
Helper IV

Re: IF statement in table using measures,

I gave up waiting and worked it out lol, just need to add the Year bit in, which i'll sort out easily.

 

Measure 3 = if([Measure 2]>= MONTH(TODAY()),[Measure 2],[Measure 4])

View solution in original post

Helpful resources

Announcements
May 2020 Community Highlights

May 2020 Community Highlights

It’s time for another PBI Community recap!

Community Blog

Community Blog

Visit our Community Blog for articles, guides, and information created by fellow community members.

Using the Community

Using the Community

Need help with the Power BI Community? Our 'Using the Community' support articles are a great place to start.

Galleries

Galleries

Looking for inspiration on how to present your data? Need instructional videos? Check out our Galleries!

Top Solution Authors
Top Kudoed Authors