The ultimate Microsoft Fabric, Power BI, Azure AI, and SQL learning event: Join us in Stockholm, September 24-27, 2024.
Save €200 with code MSCUST on top of early bird pricing!
Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started
Hello,
I have a data of 4 columns of data types : date, string, int & float. string contains about 20 different items.
I need to insert a slicer that allows to select only a subset of those 20, about 6 of them. The remaining should not be seen or be accessible. And I would like to do that by adding a new column. If I should add or remove I would do that in the new column.
Please help.
Thanks Power BI community!
Hello @chari7595,
You can create a new column in your data model that identifies the subset of items you want to include in your slicer. E.g.
SlicerColumn = IF(
OR(
Table[ItemColumn] = "Item1",
Table[ItemColumn] = "Item2",
Table[ItemColumn] = "Item3",
Table[ItemColumn] = "Item4",
Table[ItemColumn] = "Item5",
Table[ItemColumn] = "Item6"
),
Table[ItemColumn],
BLANK()
)
Should you have any questions or further assistance, please do not hesitate to reach out to me.
Thanks but i do have to ask this. What is the function of OR in the syntax ?
@chari7595 The OR function is checking to see if Table[ItemColumn] equals any of the items ("Item1", "Item2", "Item3", ....).
If Table[ItemColumn] matches any of these items, the OR function returns TRUE and the SlicerColumn will be assigned the value of Table[ItemColumn].
Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.
Check out the August 2024 Power BI update to learn about new features.
User | Count |
---|---|
113 | |
81 | |
75 | |
52 | |
48 |
User | Count |
---|---|
133 | |
124 | |
78 | |
64 | |
61 |