I need some help on sum the Negative and Positive values within a measure seperately.
Eg. I have the following measure
Since it a measure I have problems in using the CALCULATE or SUM or any other ways to calculate the sum, I nee to calculate only the negative values and have it in a measure then sum the psoitive values and have it in a different measure.
Result should be -254 for negative sum and 1.7 for the positive.
Please it would be great if some one could help me.
Solved! Go to Solution.
Hope! this is what you're looking for,
Posstive = CALCULATE(SUM(Table1[Difference]),Table1[Difference] > 0)
Negative = CALCULATE(SUM(Table1[Difference]),Table1[Difference] < 0)
@Zubair_Muhammad Thanks for your reply,
Here you mean the column
SUM ( TableName[Difference]
However mine was a measure (The difference Iam calculating is already withing a measure), I not able to use a measure here.
@SivaMani thaks for the reply
I have tried this earlier with lot other however the problem was that the difference column shown itself is a measure not the column and so it is not possible to use the measure in place of column, any other thoughts?,
I brought the negative and positive values in a speperate measures respectively but you know the total will not be the one as expecteed in a measure put up like this,, so stuck here....
We're excited to announce our first cross-community 'Can You Solve These?' challenge!
Visit our Community Blog for articles, guides, and information created by fellow community members.
Wondering what events you could join or have an event to promote yourself? Check out our Upcoming Events.
We are thrilled to announce we will begin running a monthly webinar series named Power BI Dev Camp.