Forum Discussion
cmckinney
5 years agoHelper IV
IF statement not recognizing table
I am writing an if statement in a measure that says essentially: IF( 'table'[this_date] > 'table'[that_date], 1, 0) but for some reason Power BI is not recognizing the table/columns. The table refere...
PhilipTreacy
5 years agoSuper User
Hi cmckinney
You need to aggregate the data in someway when creating a measure so you need to write something like this
Pass_Fail_Flag = IF( MAX('test vPassFailTestResults'[Last Failed]) > MAX('test vPassFailTestResults'[Last Passed]), 0,1 )
Alternatively you could create a Calculated Column and your current syntax would then work without using an aggregation function.
regards
Phil
If I answered your question please mark my post as the solution.
If my answer helped solve your problem, give it a kudos by clicking on the Thumbs Up.