TamirBasin
New Member
- Joined
- Apr 11, 2017
- Messages
- 49
- Office Version
- 365
- Platform
- Windows
Hi
This is a re-post from the Power BI community: Return a Table With a SWITCH
The solution given solved my business need, but not my DAX challenge.
The below code should return a table ("_TableAdi" or "_TableTamir") but instead, I get an error.
I'm getting the following error: "The expression specified in the query is not a valid table expression."
Can anyone suggest a solution?
Thank you,
Tamir
This is a re-post from the Power BI community: Return a Table With a SWITCH
The solution given solved my business need, but not my DAX challenge.
The below code should return a table ("_TableAdi" or "_TableTamir") but instead, I get an error.
Code:
dynamicSlicer =
VAR _TableAdi = SUMMARIZECOLUMNS(COSTORCOUNT[Flag])
VAR _TableTamir = SUMMARIZECOLUMNS(COSTORCOUNT[Flag],FILTER(COSTORCOUNT,COSTORCOUNT[Flag]=0))
VAR _Switch = IF( SELECTEDVALUE(parameterTable[parameter]) = 1,
_TableAdi, _TableTamir)
return _Switch
I'm getting the following error: "The expression specified in the query is not a valid table expression."
Can anyone suggest a solution?
Thank you,
Tamir