Forum Discussion
FJV
3 years agoFrequent Visitor
Explicit vs implicit measure with value on the one side
Consider the following situation with to tables in a optional one (A)-to-many (B) relation and an value on the one side: Table A TableA_ID, Value A, 10 B, 20 C, 30 Table B TableB_ID, Des...
- 3 years ago
// Given: // A ( 1 -- one-way-filtering --> : ) B [Your Measure] = SUMX( SUMMARIZE( 'Table B', 'Table A'[TableA_ID], 'Table A'[Value] ), 'Table A'[Value] )In Power BI it DOES MATTER which column you pull from which table... so you have to be careful how you code your measures.
daXtreme
Solution Sage
3 years ago
// Given:
// A ( 1 -- one-way-filtering --> : ) B
[Your Measure] =
SUMX(
SUMMARIZE(
'Table B',
'Table A'[TableA_ID],
'Table A'[Value]
),
'Table A'[Value]
)
In Power BI it DOES MATTER which column you pull from which table... so you have to be careful how you code your measures.
FJV
3 years agoFrequent Visitor
Thanks a lot! This works fine and I can understand the solution.
But I am still wondering why the implicit meassure acts different than a sum(A[value]). When reading about implicit measures (those given by Power BI to numeric fields with the sigma-sign), the suggestion is given that it does a simple SUM. Apparently not...? Does anyone have some details on this?
- daXtreme3 years ago
Solution Sage
Rule of thumb: Never use implicit measures. NEVER. Always write your own. You'll save yourself time, effort and grief.