Forum Discussion
Anonymous
3 years agoNot applicable
Return a Table With a SWITCH
hi, I have the following table: "COSTORCOUNT" and a parameter table: "parameterTable" I'm tring to return a table according to selectedvalue from the "parameterTable" I put the pa...
- 3 years ago
Anonymous I've never had any luck with DAX being able to return one table or another table. It doesn't like it. Try this instead:
dynamicSlicer = VAR _Selected = SELECTEDVALUE(parameterTable[parameter]) VAR _Table = SUMMARIZE(FILTER(COSTORCOUNT, [Flag] = _Selected),[Flag]) RETURN _Table
Greg_Deckler
Community Champion
3 years agoAnonymous I've never had any luck with DAX being able to return one table or another table. It doesn't like it. Try this instead:
dynamicSlicer =
VAR _Selected = SELECTEDVALUE(parameterTable[parameter])
VAR _Table = SUMMARIZE(FILTER(COSTORCOUNT, [Flag] = _Selected),[Flag])
RETURN
_Table