Building a query
A Saiku query is built by dragging fields into the drop zones at the top of the workbench. There’s no SQL to write and no MDX either — the UI generates the query for you as you compose. This page covers the moves you’ll use over and over.
The minimum useful query
-
Open the cube from Analyze.
-
Drag a measure (e.g. Revenue) into the Columns drop zone.
-
Drag a dimension level (e.g. Time › Year) into Rows.
-
Wait a moment. The result table renders.
That’s it — you have a year-by-year revenue table.
The same workflow with two measures: drag another measure to Columns. Two dimension levels: drag another level into Rows. Saiku composes them automatically.
Drilling down
Click any parent value in the result. The next level expands underneath. So a row showing 2024 expands to show Q1 2024, Q2 2024, etc. Click any of those to drill to months. Click again to drill to days.
Two modes for what happens to the parent row:
- Drill to detail (default) — the parent stays visible with its children indented under it. Use this when you want totals alongside the breakdown.
- Replace — the parent disappears; only children remain. Useful when the parent’s total isn’t interesting and you want the screen real estate for the detail.
Right-click a value for the menu of drill options.
Filtering
Three kinds of filter, depending on what you want to restrict.
Member filter. Pick which values of a dimension to include. Drag a level into the Filters drop zone, then click the filter row to open the selector. Check the members you want; uncheck the rest. Use this for “only show the South-West region” or “only show these three product lines”.
Date filter. Specifically for date hierarchies. Drag a date level into Filters, click the filter row, and pick a range — last 7 days, this month, last quarter, custom date range. The UI handles whatever the cube’s date hierarchy supports.
Custom filter (MDX). Power-user mode for filters the simple member selector can’t express (“top 10 products by revenue”, “customers whose total spend > 1000”). The filter dialog has an MDX text box for free-form expressions. Saved as part of the workbook.
Sorting
Click a column header in the result to sort by that column — ascending the first click, descending the second, off the third. The current sort is shown by an arrow icon on the header.
Sort by a measure to rank rows (“highest-revenue regions first”). Sort by a dimension level to alphabetise.
Top-N
For “show me the top 10 products by revenue”, combine sort with a filter:
- Drag the Product Name level into Rows.
- Drag the Revenue measure into Columns.
- Click the Revenue column header to sort descending.
- Open the filter dialog for the Product Name level, switch to Top N, set N = 10, pick the measure (Revenue) and direction (top).
The result table shows only the top 10 products by revenue, sorted descending.
Calculated members
Sometimes you want a value that isn’t directly in the cube —
“profit margin” derived from revenue - cost. Calculated members
let you express that without changing the schema.
The Calculated Members menu lives in the measures section.
Click Add, give it a name, write an MDX expression
([Measures].[Revenue] - [Measures].[Cost] for example), set the
format ("#,##0"), save. The new measure appears in the sidebar
and you can drag it like any other.
Calculated members are scoped to the current workbook. To share them across workbooks, save the workbook with the calculation in place, then open and “Save as” to spin off variants.
Saving sub-queries
Long analyses sometimes need a stepping stone — a query whose result feeds the next query. Saiku supports this via named sets and sub-cubes, both accessible from the calculated- members area. Beyond the scope of this page; see the upstream Saiku docs at saiku.meteorite.bi for the deep dive.
Drillthrough
Sometimes you want to see the raw fact-table rows behind a single cell. Right-click the cell and pick Drill through — Saiku runs the equivalent SQL against the warehouse and shows you the underlying rows.
This bypasses the cube’s aggregation entirely. Useful for “why is this number so high?” investigations and for verifying that a weird-looking result really does reflect what’s in the warehouse.
You can export the drillthrough rows directly (Excel / CSV) — see MDX & export.
Drill across
A drill-across query traverses multiple cubes that share a
dimension. If you have a Sales cube and an Inventory cube
both keyed on Product, you can drill across to bring inventory
levels into a sales analysis. Same right-click menu.
When auto-run gets in the way
For complex pivots you want to compose the layout before firing the query. Toggle auto-execution off on the toolbar; drag fields around freely; click Run query when ready. Each query run shows a small spinner; click Cancel if a long-running query needs to be killed.
What you’re actually building
Behind the scenes, every drag-and-drop in the workbench compiles to an MDX query. Show MDX on the toolbar opens a panel with the current query. For most analyses you’ll never need it, but it’s useful for:
- Debugging unexpected results.
- Copying into another tool that speaks MDX.
- Hand-tuning before saving.
The MDX & export page covers the MDX editor in detail.
Where to go next
- Charts and visualisations — pick the right visual for the question.
- Getting insight from your data — the narrative version: how analysts actually use these tools to answer real questions.
- MDX & export — the MDX editor + the Excel / CSV / PDF export options.