Forum Discussion
Anonymous
4 years agoNot applicable
Comparing two table columns which is having Many to many relationship
i have a two table in power bi . i want to compare the values between two tables if values is matched it should return True . if values not matched its should be return false . My table 1: SID ...
- 4 years ago
Anonymous OK try this, and update the column names in the last row of the measure
Status = VAR _A = CALCULATE( MAX( vw_IntegrationDataCheck[CMN] ), FILTER( vw_IntegrationDataCheck, vw_IntegrationDataCheck[ColumnType] = MAX( Out_DataComparison_Totals[columntype] ) && vw_IntegrationDataCheck[CalendarYear] = MAX( Out_DataComparison_Totals[CalendarYear] ) ) ) RETURN IF( MAX( Out_DataComparison_Totals[EO_IN_Tables] ) = _A && MAX( Out_DataComparison_Totals[EO_Out_Tables] ) = _A && MAX( Out_DataComparison_Totals[ IN_Tables] ) = _A, TRUE(), FALSE() )If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
LinkedIn: www.linkedin.com/in/vahid-dm/
VahidDM
Super User
4 years agoHi Anonymous
Try this code to add a new column:
Status =
VAR _A =
CALCULATE(
MAX( 'Table (2)'[CMN] ),
FILTER(
'Table (2)',
'Table (2)'[columntype] = EARLIER( 'Table'[columntype] )
&& 'Table (2)'[year] = EARLIER( 'Table'[year] )
)
)
RETURN
IF( [EO_IN] = _A, TRUE(), FALSE() )
output:
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
LinkedIn: www.linkedin.com/in/vahid-dm/