Oct 06 2022 01:02 AM
Hi,
I created a table from Power Query and I created several Slicers (Dept, ID, Date, Time). This to dynamically filter the list of rows displayed by the table. Also I created a pivot table to display some analysis of this filtered rows.
My problem is that I can't make the Slicers I created for the table to be also connected to Pivot Table. Because the option to connect is Dimmed in these slicers. Also, If I created slicers from the pivot table, I can't link them to the table.
The objective is to link all slicers to both data table and Pivot table so I can work and display the list of rows and analysis for same resource. Note I tried to create the slicers for the data table, then use the define a table name and use the table name in the Pivot table, but the pivot table somehow ignores the filtered data and work on the data table rows as a whole.
Oct 06 2022 01:31 AM
@Thamer_Tarabzouni You simply can't. Slicers can only connect to multiple pivot tables provided they share the same source data.
Oct 13 2022 03:23 AM
Oct 13 2022 04:04 AM
@Thamer_Tarabzouni A slicer connected to a Table can only control that one table. Accordingly, the Report Connections button is greyed out. Pressing a button on such a slicer has the same effect as filtering rows with the filter button in the column headers of the table. It merely hides/unhides rows. Pivot Tables that have such a Table as their source are not affected by the "Table-slicers".
However, when you create multiple pivot tables from the same source, you can create a set of slicers that connect to all pivot tables that share the same pivot cache.
If this makes no sense to you, I may have misunderstood your intentions.
Oct 13 2022 08:27 AM
To clarify things, is this what you're trying to achieve?
where the 2 slicers (Customer & Product) are connected to and filter the Data and the Pivot?
Oct 15 2022 10:57 PM
Oct 15 2022 10:58 PM
Oct 19 2022 09:27 AM
Dec 06 2023 05:23 AM
Dec 06 2023 06:45 AM
Actually, as you probably experienced, this isn't possible as of today
A possible workaround is doc. in Slicer on Table and PivotTable (works with > 1 slicer)
If you have issue putting this in place please let me know and share (i.e. with OneDrive, Google Drive or the like) a representative workbook - Thanks
Dec 06 2023 01:59 PM
Nice article!
Dec 06 2023 02:15 PM
This doesn't directly answer your question but, since I have always disliked Table filters that simply hide rows, I took a slightly different route. Namely, I linked the slicers to a Pivot Table and then read the PT Row Labels in order to apply the 365 FILTER function to the source data table.
= LET(
include, BYROW(InputTable[Name]=TOROW(rowLabels, 3), ORλ),
data, FILTER(InputTable, include),
totals, HSTACK("Totals", "", SUM(TAKE(data,,-1))),
VSTACK(InputTable[#Headers], data, totals)
)
Dec 06 2023 11:45 PM
Nice one too. Doable with > 1 slicer?
Dec 07 2023 06:50 AM
Doable, yes. But I don't know whether it is the best approach or whether it would be better to have a separate helper pivot table for each dimension.
= LET(
region?, BYROW(InputTable[Region] = UNIQUE(TOROW(rowLabels1, 3)), ORλ),
sector?, BYROW(InputTable[Sector] = UNIQUE(TOROW(rowLabels2, 3)), ORλ),
data, FILTER(InputTable, region? * sector?),
totals, HSTACK({"Totals", "", ""}, SUM(TAKE(data, , -1))),
VSTACK(InputTable[#Headers], data, totals)
)
Dec 08 2023 08:23 AM
Do you mind if I update the article I shared the other day, adding a link to this discussion and mentionning your 365 alternative?
(interesting to note that since I posted the article it got 20 more views, still nobody found it helpful)
Dec 08 2023 09:12 AM
Of course you may, use what you want and by all means put your own spin on it!
I did set up a help forum on LinkedIn for Lambda questions but it is still pretty much dead. I do wonder to what extent the Excel user base is even aware of the extent to which the art of spreadsheet development has changed. Power Query is still grossly underused and for Lambda it appears to be even worse.
Dec 08 2023 10:06 AM
Thanks @PeterBartholomew1
...by all means put your own spin on it! I won't, am too lazy 🙂
Dec 22 2023 12:09 AM
Forgot to mention that I updated the article the other day. Hope that's fine with you otherwise let me know what should be changed & Thanks again
(obviously nothing was good enough to deserve any kind of feedback from @tomasnavarro ...)