This is indigestible problem I have been going through, actually I am trying to list those team who played against the another team. So, when I am manually entering team name in DAX calculation it is showing me desire output but as I am trying to make it dynamic means getting value from SELECTEDVALUE() then it doesn’t showing anything. Below, I have mentioned the code, kindly provide me the solution why it is happening like this?
TeamAgainstScore =
VAR ctry = "CAN" | **SELECTEDVALUE(Matches[Country])**
RETURN
CALCULATE(
SUM('Mathces Details'[Score]),
FILTER(
'Mathces Details',
'Mathces Details'[Country] <> ctry &&
(
'Mathces Details'[match_id] IN
CALCULATETABLE(
VALUES('Mathces Details'[match_id]),
'Mathces Details'[Country] = ctry
)
||
SEARCH(ctry, 'Mathces Details'[match_id], 1, 0) > 0
)
)
)