Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
I had to find ou if a list of selected values is in a list of values, but I was facing an error: "A table of multiple values was supplied where a single value was expected", which is relevant.
I finally solve this using this:
VAR SelectedChannels = VALUES(DIM_CHANNEL[CHANNEL_NM])
VAR letters = {"aa", "bb", "cc"}
VAR numbers = {"1","2"}
RETURN
SWITCH(
TRUE(),
COUNTROWS(FILTER(SelectedChannels, NOT([CHANNEL_NM] IN letters ))) = 0, "Letters",
COUNTROWS(FILTER(SelectedChannels, NOT([CHANNEL_NM] IN numbers))) = 0, "Numbers",
// Neither letters nor numbers and 1 selected value
COUNTROWS(SelectedChannels) = 1, SelectedChannels,
"Multiple other values"
)
Hi @Jaggana
Thank you for reaching out to the Microsoft Fabric Forum Community.
Great job, This is a very useful tip for the community, thanks for taking the time to share your solution.
@Jaggana , Try like
VAR SelectedChannels = VALUES(DIM_CHANNEL[CHANNEL_NM])
VAR letters = {"aa", "bb", "cc"}
VAR numbers = {"1","2"}
RETURN
SWITCH(
TRUE(),
COUNTROWS(FILTER(DIM_CHANNEL[CHANNEL_NM], NOT([CHANNEL_NM] IN letters ))) = 0, "Letters",
COUNTROWS(FILTER(DIM_CHANNEL[CHANNEL_NM], NOT([CHANNEL_NM] IN numbers))) = 0, "Numbers",
// Neither letters nor numbers and 1 selected value
COUNTROWS(SelectedChannels) = 1, CONCATANATEX(SelectedChannels,[CHANNEL_NM], " ,"),
"Multiple other values"
)
Thank you @amitchandak but it works fine, I am just giving a tip to the community 🙂
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!