cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
mrrob
Frequent Visitor

Using slicer to filter columns

Hi!

Is it possible to filter columns using one slicer? I would like to add few table columns to 'values' (axis x doesn't change it's a date) and pick on slicer which value should be displayed.

 

Thanks in advance.

1 ACCEPTED SOLUTION
BhaveshPatel
Community Champion
Community Champion

Please see the attached screenshots for the solution.Select the Date column and Create a Query step - unpivot other columnsSelect the Date column and Create a Query step - unpivot other columnsCreate a samples tableCreate a samples tableCreate a connection with Samples TableCreate a connection with Samples TablePrepare a line chart with all the fields coming from the first tablePrepare a line chart with all the fields coming from the first tableSlicer should be coming from the Samples TableSlicer should be coming from the Samples Table

Thanks & Regards,
Bhavesh

Love the Self Service BI.
Please use the 'Mark as answer' link to mark a post that answers your question. If you find a reply helpful, please remember to give Kudos.

View solution in original post

11 REPLIES 11
kelly4dm
Helper I
Helper I

Have you tried to use the heirarchyslicer in https://app.powerbi.com/visuals/ ?

mrrob
Frequent Visitor

@kelly4dm I don't want to build hierarchy between them. Unfortunately, I can't use that slicer without building hierarchy. It isn't result that I expect.

shebr
Resolver III
Resolver III

Hi @mrrob, you can also use the 'Edit Interactions' button on the menu, that you can either filter or highlight selected items. You can also stop interactions between certain items too. Have a play with it!

 

Cheers

 

Shebr

BhaveshPatel
Community Champion
Community Champion

Yes. It is a native behaviour of PowerBI. For Example, If the column A in Table is filtered, all the associated records in other columns will also be filtered. 

Records in the year 2009Records in the year 2009Records in the year 2011Records in the year 2011

 

Thanks & Regards,
Bhavesh

Love the Self Service BI.
Please use the 'Mark as answer' link to mark a post that answers your question. If you find a reply helpful, please remember to give Kudos.

@BhaveshPatel I know but it isn't what I want to do.

I would like to do something like that (line chart):

x axis: date (column from table 1)

y axis: sample1, sample2, sample3 (columns from table 1)

and simple slicer to pick which of sample should be displayed on the line chart at the moment.

It isn't row filtering. 

BhaveshPatel
Community Champion
Community Champion

Please see the attached screenshots for the solution.Select the Date column and Create a Query step - unpivot other columnsSelect the Date column and Create a Query step - unpivot other columnsCreate a samples tableCreate a samples tableCreate a connection with Samples TableCreate a connection with Samples TablePrepare a line chart with all the fields coming from the first tablePrepare a line chart with all the fields coming from the first tableSlicer should be coming from the Samples TableSlicer should be coming from the Samples Table

Thanks & Regards,
Bhavesh

Love the Self Service BI.
Please use the 'Mark as answer' link to mark a post that answers your question. If you find a reply helpful, please remember to give Kudos.

View solution in original post

Thanks for solution. 

One additional question. Can I change this slicer to multi select slicer? Now when I check 2 boxes the slicer summarize 2 samples column values to one line. 

BhaveshPatel
Community Champion
Community Champion

Yes. You can do that as well. You need to create Index Column in your Fact Table in the Query Editor.

To do so, Go to the Edit Queries, Go to " Add Column" Tab, Select "Add Index Coulmn", Select From 1.

Load your Query Now. 

 

Prepare the Graph as shown in the screenshot and You can view the 3 different lines for 3 different Samples.

 

3 lines for 3 samples.3 lines for 3 samples.

Thanks & Regards,
Bhavesh

Love the Self Service BI.
Please use the 'Mark as answer' link to mark a post that answers your question. If you find a reply helpful, please remember to give Kudos.
BhaveshPatel
Community Champion
Community Champion

Thank you for your clarification. I don't think so you can put on columns on the slicer.

Thanks & Regards,
Bhavesh

Love the Self Service BI.
Please use the 'Mark as answer' link to mark a post that answers your question. If you find a reply helpful, please remember to give Kudos.

Any ideas how can I do it another way? 

BhaveshPatel
Community Champion
Community Champion

I am trying a solution for you. Once done, will definitely let you know.

Thanks & Regards,
Bhavesh

Love the Self Service BI.
Please use the 'Mark as answer' link to mark a post that answers your question. If you find a reply helpful, please remember to give Kudos.

Helpful resources

Announcements
MBAS on Demand

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

July 2021 Update 768x460.png

Check it out!

Click here to read more about the July 2021 Updates

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

Top Solution Authors
Top Kudoed Authors