How-to
How to build a pivot table in Hubviz Studio
Cross cube fields in rows and columns, sum, count or average the values, filter and show totals in a Hubviz Studio pivot table.
A pivot table crosses cube fields in rows and columns and summarizes the values at each intersection. For example: the revenue of each business unit in each quarter, with the grand total at the bottom.
When to use it
- To compare many numbers side by side, such as business unit by quarter or product by region.
- When readers want exact values, not just the trend.
- To count records (how many sales), find the minimum or maximum, or see each row’s share of the total.
If you only want the list of cube records, with no summary, use a data table. If you want the trend over time, a line or column chart reads better.
Create the pivot table
-
In the project side menu, open Charts. Click the Pivot Tables section to expand it, click Add New and choose New Pivot Table. The editor opens in a new tab.
-
Under Data Table Configuration, pick the cube in Cube to Display Data and type a name in Table Name. The Available Fields list shows the cube fields.
-
Drag a text field, such as Business unit, to Rows. Each value of the field becomes a row.
-
Drag the date field to Columns. Each date becomes a column; in the next step you group it by quarter.
-
Drag the numbers you want to summarize, such as Revenue and Gross profit, to Values. Each field is added as a sum.
-
Adjust each field with the gear icon on its card (see Field options, below). The Table Data Preview updates right away.
-
Save with Ctrl + S.
The same field can go into more than one area, for example Business unit in Rows and also in Filters. To remove a field, click the x on its card. To change the order, drag the card inside the area or to another area.
The four areas
| Area | What it does | Example |
|---|---|---|
| Rows | Each value of the field becomes a row. With two fields, the second one sits inside the first. | Business unit, and inside it the Product. |
| Columns | Each value of the field becomes a column. | Date grouped by quarter. |
| Values | The numbers summarized at each intersection. With two values, each column splits in two. | Revenue and Gross profit. |
| Filters | Limits the records that go into the table, without showing the field. | Only Industry and Retail. |
An empty area shows Drag fields here.
Field options
Click the gear on a card to open the field menu. What you see depends on the area.
Fields in Values
| Option | Choices | Default | When to change it |
|---|---|---|---|
| Aggregator | Sum, Count, Distinct Count, Average, Minimum, Maximum | Sum | Count to know how many sales there were; Distinct Count for how many different customers; Average for the average ticket. |
| Display Mode | Value, % of Total, % of Row, % of Column | Value | % of Column shows how much each unit represents in the quarter. % of Row shows how a unit’s revenue splits across quarters. |
| Format | Default, Number, Currency, Percentage, Number without decimals, Hours | Default | Only changes how the number looks. The calculation stays the same. |
| Formula Evaluation | Before aggregation, After aggregation | Before aggregation | Only shows up for calculated fields (the fx badge). See below. |
Fields in Rows and Columns
| Option | Choices | Default | Note |
|---|---|---|---|
| Date grouping | Full date, Year, Semester, Quarter, Month, Week, Day | Full date | Date fields only. With Full date, every different day becomes a column. |
| Row label layout | Nested (outline), Tabular (column) | Nested | Rows only. Nested shows the levels as an outline that expands and collapses. Tabular puts each level in its own column, like Excel. You can mix both. |
| Sort order | Ascending (A-Z, 0-9), Descending (Z-A, 9-0) | Ascending | Order of the row or column labels. |
To change the name shown in the header, use Edit label on the card. The original name comes back with Reset label in the gear menu.
Fields in Filters
On a Filters card the icon is a funnel. It opens Select Values: search, tick the values to include, or use Select All and Clear.
For date fields, the filter works by Period: pick one of the Quick periods, such as this quarter or year to date, or a Custom range.
Table options
They sit under Data Table Configuration, above the field list.
| Option | What it does | Default |
|---|---|---|
| Show row totals | Shows subtotal rows for each group of rows. Useful with two fields in Rows. | Off |
| Do not limit row label column width | Lets the label columns take more than half of the width. Use it when long names show up cut off. | Off |
| Allow changes in Dashboard | Shows a pencil on the table inside the dashboard. Whoever edits the dashboard adjusts the fields right there, with Edit pivot table, and confirms with Save changes or Discard changes. | Off |
The Grand Total row always shows at the end of the table.
Read and sort the table
- Click the arrow next to a value in the header to sort the rows by it. The first click sorts from lowest to highest, the second from highest to lowest and the third goes back to the normal order.
- The arrow next to the row field name sorts the labels alphabetically.
- In the nested layout, click a group label to expand or collapse the items inside it.
Example: revenue by business unit and quarter
In the Sales Results 2026 sample project, the Sales cube has Date, Business unit, Revenue, Cost, Target and the calculated field Gross profit.
- Date in Columns, with Date grouping set to Quarter.
- Business unit in Rows.
- Revenue and Gross profit in Values, both with Format set to Currency.
The result shows that Industry had R$ 4,925,551.00 in revenue in the first quarter of 2026, and the quarter’s Grand Total was R$ 11,292,719.00. To see each unit’s share, switch the Revenue Display Mode to % of Column: each column then adds up to 100%.
Watch out
- Full date creates too many columns. A cube with one year of daily sales becomes 365 columns. Group by month or quarter.
- The format does not round the calculation. Number without decimals only hides the decimals; totals use the exact value.
- Adding up what should not be added. Unit prices, percentages and balances make no sense as sums. Use Average, Minimum or Maximum, or a calculated field with After aggregation.
- Dashboard filters do not narrow the table in Hubviz Studio. The pivot table reads the cube records, and Hubviz Studio keeps the full records when a dashboard filter is applied. To narrow the table, use its own Filters area.
- To place the table on a dashboard, see How to build a dashboard. It shows up in the pivot tables group of the picker.