cancel
Showing results for
Did you mean: Anonymous
Not applicable

## Count Rows with a Sum Condition

Hi Experts

My current measure gives me the correct count of row

Total= CALCULATE(COUNT('STG Fact_'[Actual_end_date])

i want to apply the £ value to that count
my mesure that gives me the £ value is
[Annual Value (£)]

1 ACCEPTED SOLUTION  Super User

@Anonymous

Can you try this measure, need more explanation though.

``````Measure  =

VAR __M =  CALCULATE(COUNT('STG Fact_'[Actual_end_date]) ) RETURN

IF( _M = 5 , [Annual Value (£)] , BLANK() )``````

________________________

If my answer was helpful, please consider Accept it as the solution to help the other members find it

Click on the Thumbs-Up icon if you like this reply 🙂

Did I answer your question? Mark my post as a solution! and hit thumbs up
6 REPLIES 6 Anonymous
Not applicable

@route217

``Total= CALCULATE(COUNT('STG Fact_'[Actual_end_date]))*130.76 &" " &UNICHAR(163)`` Anonymous
Not applicable

Apologies I have not explained the question probably.. if the count measure gives 5, then the £ measure with count must give 16. Not the £ sign added to the count

 Date Value £ 01/09/2020 3 02/09/2020 4 03/09/2020 2 04/09/2020 3 05/09/2020 4 5 16  Super User

@Anonymous

Can you try this measure, need more explanation though.

``````Measure  =

VAR __M =  CALCULATE(COUNT('STG Fact_'[Actual_end_date]) ) RETURN

IF( _M = 5 , [Annual Value (£)] , BLANK() )``````

________________________

If my answer was helpful, please consider Accept it as the solution to help the other members find it

Click on the Thumbs-Up icon if you like this reply 🙂

Did I answer your question? Mark my post as a solution! and hit thumbs up Anonymous
Not applicable  Anonymous
Not applicable

Hi Fowmy

from my model,I can count the Agreement_ closed (Table B) which links to my fact table A - table C is the values Table. All tables are connect via Merchant_ID (primiary key) no direct relationship between Table B and C.

I can count the closed Agreement in Table B using

CALCULATE(COUNT('STG Fact'[Actual_end_date]) ) and the value is correct

to each of those closed agreement i want to add the £ cost - i how much in money was lost as a result of closing that agreement. Anonymous
Not applicable
Then multiply with the rate you have. I have edited the DAX you can use that or refer it to write the DAX.   