Forum Discussion

ponchibonos's avatar
ponchibonos
Helper I
1 year ago
Solved

Conditional column with specific values

Hello. I have the results of a survey in which the answers are “yes” and “no”. From Power query with the conditional column function I transformed the answers “Yes” to 1 and “No” to 0. The problem I...
  • Jihwan_Kim's avatar
    1 year ago

    Hi,

    Please check the below picture and the attached pbix file.

     

     

    = Table.AddColumn(Source, "Expected result", each if [Questions] = "Question 3" then if [Answer] = "No" then 1 else 0 else if [Answer] = "Yes" then 1 else 0)