Forum Discussion
Bootkie2
6 years agoFrequent Visitor
Help with This &&& || Statement
I have a really dumb question. I have a table with a UserId a Question Id and an Answer. I'm trying to call out user Ids who answered "No" to q_1 But they must have said "Yes" in either q_2, q_3, or...
- 6 years ago
Create a table
TableU = INTERSECT( SELECTCOLUMNS(FILTER(TableD, TableD[Qid] = "q_1" && TableD[Answer] = "No"),"user", TableD[userID]), SELECTCOLUMNS(FILTER(TableD, TableD[Qid] in {"q_2", "q_3", "q_4"} && TableD[Answer] = "Yes"),"user", TableD[userID])) - 6 years ago
amitchandak
6 years agoSuper User
You summarize table need to like this
SUMMARIZE (AnswerTable
,AnswerTable[UserID]
,"_q1_NO" ,calculate(count(AnswerTable[Qid]),AnswerTable[Qid] = "q_1" && AnswerTables[Answer] = "No")
,"_q1_except" ,calculate(count(AnswerTable[Qid]),AnswerTable[Qid] <> "q_1" && AnswerTables[Answer] = "No")
)If [_q1_NO]=1 && [_q1_except] is the condition you are looking for. You can buildup, rest of the logic on top of it
Appreciate your Kudos. In case, this is the solution you are looking for, mark it as the Solution. In case it does not help, please provide additional information and mark me with @
Thanks. My Recent Blog -
Winner-Topper-on-Map-How-to-Color-States-on-a-Map-with-Winners , HR-Analytics-Active-Employee-Hire-and-Termination-trend
Power-BI-Working-with-Non-Standard-Time-Periods And Comparing-Data-Across-Date-Ranges
Connect on Linkedin