Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
I'd simply like to get the distinct values for a particular column that is filtered by another column.
Here is my attempt, but I get the following error:
The VALUES function expects a column reference expression or a table reference expression for argument '1'.
VALUES(
SELECTCOLUMNS(
FILTER(Table,
Table[B] in{"apples","oranges"}
),
"Distinct Column A Values",Table[A]
)
)
Solved! Go to Solution.
Use the following code to create a new table from the modeling tab > New Table
New Table =
CALCULATETABLE(
VALUES(Table[A]),
Table[B] in {"apples","oranges"}
)
________________________
If my answer was helpful, please consider Accept it as the solution to help the other members find it
Click on the Thumbs-Up icon if you like this reply 🙂
⭕ Subscribe and learn Power BI from these videos
⚪ Website ⚪ LinkedIn ⚪ PBI User Group
Use the following code to create a new table from the modeling tab > New Table
New Table =
CALCULATETABLE(
VALUES(Table[A]),
Table[B] in {"apples","oranges"}
)
________________________
If my answer was helpful, please consider Accept it as the solution to help the other members find it
Click on the Thumbs-Up icon if you like this reply 🙂
⭕ Subscribe and learn Power BI from these videos
⚪ Website ⚪ LinkedIn ⚪ PBI User Group