Forum Discussion

acg's avatar
acg
Resolver I
3 years ago
Solved

Creating a new Table based on conditions

I need to create a new table in power BI to write down the follwing (sql)condition: WITH CTE_1 AS ( --Yes/No Logic applied SELECT * FROM [IDW_mart_DEV].[dbo].[v_q] WHERE ([Question Code] = 'CFO...
  • MahyarTF's avatar
    3 years ago

    Hi,

    Use in {} in your Code :

    Yes/No Logic =
    CALCULATETABLE('Fact QNA','Dim Questions'[Question Code] in {"CFOFRQ0036" , "CFOFRQ0037"} ,'Fact QNA'[Answer Boolean Value] in {"Yes", "No"})
    Thanks for Kudos,
    and please select it as a solution if helps