Ravindra BagaleCourses & study guides मराठी Track your progress

12. Data Hierarchies and Groups

12.4 Using Hierarchies in Visuals and Slicers

Start with a problem

Ravina wants a slicer where a manager can tick Pune, or open it and tick only Kothrud.

Explain simply

Put the hierarchy into a slicer for an expandable tree, or onto a visual's axis to drill down.

Show the data

Region City Store
West Maharashtra Pune Kothrud
West Maharashtra Pune Baner
North Maharashtra Nashik Gangapur
North Maharashtra Nashik College Road
South Maharashtra Kolhapur Rajarampuri

About this data: This table uses columns: Region, City, Store. This table uses columns: Visual, Action, Result. This table uses columns: Wrong result, Reason, Correction. Values shown are the lesson examples already on this page (not a new dataset).

Fictional sample data. Practice file: visuals_orders_apr_may_2026.csv, dark_stores_maharashtra.csv (source: src/practice/).

Demonstrate

  1. Add a Slicer › drag Location (Region › City › Store) into Field.

    Your result should look like this:

    Slicer
    ▸ North Maharashtra ▸ South Maharashtra ▸ West Maharashtra
  2. Expand West Maharashtra › Pune › tick Kothrud only.

    Your result should look like this:

    Total Sales card
    ₹650
  3. Tick Pune (the whole city).

    Your result should look like this:

    Total Sales card
    ₹850
  4. Column chart: Location on X-axis › turn on Drill down mode (↓) › click West Maharashtra.

    Your result should look like this:

    Columns
    Pune ₹850
  5. Back up › Expand all down one level (forked arrow).

    Your result should look like this:

    Columns
    North Maharashtra Nashik ₹800, South Maharashtra Kolhapur ₹450, West Maharashtra Pune ₹850

Show the result

Your result should look like this (fictional sample):

Visual Action Result
Slicer Kothrud ticked ₹650
Slicer Pune ticked ₹850
Column chart Drill into West Maharashtra Pune ₹850
Column chart Expand all down one level 3 region-city columns

Explain what happened

Ticking a parent selects all its children; ticking a child selects only that store. Drill down filters to one branch; Expand all shows the next level for every branch.

Explore further

  • The matrix uses +/- buttons for the same idea (Module 16.4).

Detailed reference for this lesson:

  • Visuals: drag the whole hierarchy (e.g. Location) into X-axis/Y-axis or matrix Rows. The drill icons appear on the visual header (Module 16). You can untick levels you do not want in that visual (click the ✕ next to a level in the field well).
  • Matrix: rows show +/- expand buttons for each level (Module 16.4).
  • Slicers: drag the hierarchy (or several fields) into a slicer's Field well. You get a hierarchy slicer with expand arrows (Maharashtra › Pune › Kothrud …). Format it in Format visual › Visual › Slicer settings (e.g. Single select) and Hierarchy (expand/collapse icons).

Practice task

Build a matrix with Location on rows and Year › Month (Date hierarchy) on columns, showing Total Orders. Add a hierarchy slicer for Product (Category › Product Name).

Ravindra Bagale's Tip

Friends, many students put a hierarchy on a visual and then wonder why drill buttons don't appear or a slicer shows a flat list. Check that the whole hierarchy (not a single level) is in the field well, and use a hierarchy slicer style when users need to expand levels. Never forget this.

Fix common mistakes

Wrong result Reason Correction
Clicking a column does nothing Drill down mode (↓) not switched on Turn on drill mode, then click
The slicer shows a flat list Only one field in the slicer Add the whole hierarchy
Pune ticked but Kothrud alone expected A parent tick selects all children Tick only the child

Practise independently

Practice task

In the slicer, tick Gangapur and Rajarampuri. What does the Total Sales card show?

Hints
  • Rajarampuri's second order was cancelled (₹0).
Solution

₹300 + ₹450 = ₹750.

Think like a professional

Hierarchy slicers save space, but test them with real users: some expect a parent tick to mean the parent only.

Ravi Sir's Cards for this lesson

मराठी cards