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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
Sachet_716
Helper I
Helper I

CY vs LY measure

hi guys, 

 

Need some help from the experts, i am preparing a report whihc shows current year and last year sales. But when i calculated the delta, it is showing me results of stores even if they dont have data for this year. How can i make it calculate only for stores whihc has sales this year? Here's my table. I only want to have data for Store 3 & 6.

 

Thanks!!

Che

 DAX.jpg

 

 

 

 

 

1 ACCEPTED SOLUTION
Thejeswar
Super User
Super User

Hi @Sachet_716,

Try the below DAX

 

Measure = IF(Table[Last Year Sales Value]=" ", " ", "your Logic for CY Vs. LY")

This will give Blank SPace whenever Last Year Sales Values is ""

View solution in original post

4 REPLIES 4
Thejeswar
Super User
Super User

Hi @Sachet_716,

Try the below DAX

 

Measure = IF(Table[Last Year Sales Value]=" ", " ", "your Logic for CY Vs. LY")

This will give Blank SPace whenever Last Year Sales Values is ""

thanks @Thejeswar, got it!  🙂

Welcome!! A Kudos along with accepting the solution would have been better!!! Smiley Very Happy

Smiley Very Happy

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

Jan NL Carousel

Fabric Community Update - January 2025

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