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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
SAPpowerbi
Helper II
Helper II

Count measure sum (Total) issue

Hello Team ,

 

I am creating DAX mesure as per my calculation Need , but i am not abel to Sum that measure , kindly help me on below dax.

 

DAX Measure - Measure 1 = IF('Revenue- 2021'[Value]<0,BLANK(),1)

 i wanted just sum of all the if count wherever 1 is showing .

 

Below Matrix Table for your referance -

 

 

Client name Revenue 2021Measure 1
ABC2001
XYZ1001
A- 
B1001
Total4003

 

I want just sum of my measure 1 - insted of 3 i am gatting 1 as a sum value kindly help me on this

 

Output - I want Measure 1 = totalsumeis 3 .

Thank you.

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@SAPpowerbi , assuming this is a measure -'Revenue- 2021'[Value]

 

Countx(values(Table[Client name]),  IF('Revenue- 2021'[Value]<0,BLANK(),[Client name]) )

View solution in original post

4 REPLIES 4
Jihwan_Kim
Super User
Super User

Hi,

Please check the below picture and the attached pbix file.

 

Slide1.jpg

 

Count measure greater than zero: =
SUMX (
    ADDCOLUMNS (
        VALUES ( Data[Client name] ),
        "@conditionmeasure", CALCULATE ( IF ( [Rev 2021 measure:] <= 0, 0, 1 ) )
    ),
    [@conditionmeasure]
)

If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Go to My LinkedIn Page


amitchandak
Super User
Super User

@SAPpowerbi , assuming this is a measure -'Revenue- 2021'[Value]

 

Countx(values(Table[Client name]),  IF('Revenue- 2021'[Value]<0,BLANK(),[Client name]) )

Thank you so much , this work for me .thnks alot God bless you .

Hi ,

Thank you for reply .
revenue 2021 value - is my column .

I am using this column and write this - Measure 1 = IF('Revenue- 2021'[Value]<0,BLANK(),1)

Kindly help me if Revnue 2021 is column than how to write in dax.

Thank you .

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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