Forum Discussion
npals
8 years agoFrequent Visitor
Detect No before Yes
Hello, I am trying to create a new measure or calculated column that will detect if "no" exists before "yes" within a row. If this instance does exist, the value would equal "1" or "true", and i...
- 8 years ago
In the query editor, you add a column with this formula:
List.PositionOf(Record.FieldValues(_), "No") < List.PositionOf(Record.FieldValues(_), "Yes")
if you need a case-insensitve check, you transfer to lower like this:
List.PositionOf(Record.FieldValues(Text.Lower(_)), "no") < List.PositionOf(Record.FieldValues(Text.Lower(_)), "yes")
ImkeF
8 years agoCommunity Champion
In the query editor, you add a column with this formula:
List.PositionOf(Record.FieldValues(_), "No") < List.PositionOf(Record.FieldValues(_), "Yes")
if you need a case-insensitve check, you transfer to lower like this:
List.PositionOf(Record.FieldValues(Text.Lower(_)), "no") < List.PositionOf(Record.FieldValues(Text.Lower(_)), "yes")