# Pivot table

### Pivoting dimensions and measures

Use the **Pivot Table** option to easily re-structure your dimensions and measures and select the aggregation for totals and subtotals.

<figure><img src="https://3062809325-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FEbkCXCUXmtUq5tcnUtZE%2Fuploads%2FK5A4SXe1VKro1plzq8AD%2F2024-12-23_08h54_18.png?alt=media&#x26;token=ee7fd660-e12b-4880-8c28-f665585a4e32" alt=""><figcaption><p>Pivot table interface</p></figcaption></figure>

### 1. Converting rows into columns

You can pivot row and column dimensions by dragging them into the respective buckets. Let's look at how to convert the Region column dimension into a row dimension.

<figure><img src="https://3062809325-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FEbkCXCUXmtUq5tcnUtZE%2Fuploads%2FNCD4SUCs0dlSvkkhKVZb%2F2024-12-23_08h57_48.png?alt=media&#x26;token=82b8a42e-f856-4e5f-9513-7961bb8e1349" alt=""><figcaption><p>Region column dimension</p></figcaption></figure>

Drag the Region dimension from the Columns bucket to the Rows bucket to pivot the columns into rows.

<figure><img src="https://3062809325-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FEbkCXCUXmtUq5tcnUtZE%2Fuploads%2FOq0No8E0QSEvFxuccpcQ%2FUntitled%20Project.gif?alt=media&#x26;token=38add5e9-d25c-4b6d-a64e-6a5e2a934f41" alt=""><figcaption><p>Column to row conversion</p></figcaption></figure>

### 2. Aggregating numeric measures

When you enable totals and subtotals, you can also specify the type of aggregation to apply: sum/average/minimum/maximum.

<figure><img src="https://3062809325-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FEbkCXCUXmtUq5tcnUtZE%2Fuploads%2FrUwsmX6IkIIP98SnimA3%2F2024-12-23_09h10_25.png?alt=media&#x26;token=608f5231-c00f-4610-bbe1-c3f25d3c1388" alt=""><figcaption><p>Aggregation type</p></figcaption></figure>

In this query, we've applied summation for the Profit measure and average for the Sales measure.

<figure><img src="https://3062809325-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FEbkCXCUXmtUq5tcnUtZE%2Fuploads%2Fj0dyyAKeB7yTIIuZi0n5%2F2024-12-23_09h12_56.png?alt=media&#x26;token=360d326a-eb15-435a-bbda-2bf33ae74d22" alt=""><figcaption><p>Aggregated measures</p></figcaption></figure>

### 3. Converting text dimensions into measures

You can convert text dimensions into measures and vice versa. Drag the dimension into the Values bucket to convert it into a measure.

### 4. Concatenating text measures

Use the **Concat** option to aggregate strings from multiple rows into a single string, with a delimiter of your choice. For instance, you can concatenate all the accounts under a particular segment and analyze data at a higher granularity, without losing any information.

<figure><img src="https://3062809325-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FEbkCXCUXmtUq5tcnUtZE%2Fuploads%2F3pBRnJmkZBplZEDMsBCE%2F2024-12-23_10h33_12.png?alt=media&#x26;token=d2c0004d-990f-4b8c-adb4-d656c0a6f264" alt=""><figcaption><p>Concatenating text measures with a delimiter</p></figcaption></figure>

Individual accounts are rolled up at Account type level, providing a concise summary of the dataset. The aggregated rows can then be consumed in other destination visuals.

<figure><img src="https://3062809325-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FEbkCXCUXmtUq5tcnUtZE%2Fuploads%2FkBCTDYJriHo6Zy3dAr3x%2F2024-12-23_10h37_34.png?alt=media&#x26;token=c13042ca-8664-4bd6-aa2e-8682224d4208" alt=""><figcaption><p>Aggregated text measure</p></figcaption></figure>
