Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hello guys,
is there a better way how to make a simple sum for specific fields in one Column than this below ?
Solved! Go to Solution.
Hi @TomaKavi
Thanks for your reply.
>> I need this measure to be a part of another measure. .... how to nest the 3 filtered values and sum them together.
The usual approach is to create a measure to calculate the total, and then create a measure to call it, for example
measure 1= sumx(filter('table', 'table '[xxx]=....),'table'[value])
measure 2=
var _totalFromM1=[measure 1]
var _expression=calculate(....)
return _totalFromM1+_expression
This is the simplest way.
Best Regards,
Community Support Team _Tang
If this post helps, please consider Accept it as the solution to help the other members find it more quickly.
actually not, I need this measure to be a part of another measure. I was more asking if there is another way ( a bit simple) how to nest the 3 filtered values and sum them together.
Hi @TomaKavi
Thanks for your reply.
>> I need this measure to be a part of another measure. .... how to nest the 3 filtered values and sum them together.
The usual approach is to create a measure to calculate the total, and then create a measure to call it, for example
measure 1= sumx(filter('table', 'table '[xxx]=....),'table'[value])
measure 2=
var _totalFromM1=[measure 1]
var _expression=calculate(....)
return _totalFromM1+_expression
This is the simplest way.
Best Regards,
Community Support Team _Tang
If this post helps, please consider Accept it as the solution to help the other members find it more quickly.
and that is the poin HOW to add more values here ,,Table [xxx] =......., how do you nest more parameters there ?
measure 1= sumx(filter('table', 'table '[xxx]=....),'table'[value])
Hi @TomaKavi
Thanks for your reply.
>> how do you nest more parameters there
You can try
measure 1= sumx(filter('table', 'table '[xxx1]=.... && 'table '[xxx2]=.... && 'table '[xxx3]=....),'table'[value])
Best Regards,
Community Support Team _Tang
If this post helps, please consider Accept it as the solution to help the other members find it more quickly.
got you, but what if we are talking about the same table, I guess the solution that I have written at the top is the only one right ?
Hi @TomaKavi
You can choose according to your scenario. If you only need to call it once, use this method.
If you need to call it multiple times, create a table.
test =
CALCULATE (
SUM(Total_2021[value]),
FILTER (
Total_2021,
Total_2021[Consolidation account] IN VALUES('filter'[Column1])
)
)
Best Regards,
Community Support Team _Tang
If this post helps, please consider Accept it as the solution to help the other members find it more quickly.
User | Count |
---|---|
22 | |
11 | |
8 | |
6 | |
6 |
User | Count |
---|---|
25 | |
13 | |
11 | |
9 | |
6 |