Horizontal and Vertical Cell Expansion
1) After a data column is inserted to a cell, its preview effect can be controlled by an attribute named cell expansion.
No expansion: When being previewed, all values in the same data column are displayed in a single cell and they are split by comma.
Expansion: When being previewed, each value in the same data column occupies a unique cell and the cells align horizontally or vertically.
2) Prerequisite: Insert Data Columns.
You will learn |
---|
|
I. No expansion
1. Create a new dataset [ds1]
1) Create a new DB Query
2) SQL statement:SELECT DISTINCT Salesperson From Sales_Volume
2. No expansion
1) Select B2 and insert a data column.
2) In the pop-up [Data Column] window, configure the following settings:
Dataset: ds1
Data Column: Salesperson
Expand Direction: No Expansion
3. Add borders for B2
4. The preview effect
Note: No expansion: When being previewed, all values in the same data column are displayed in the same cell.
II. Vertical expansion
There are two ways to modify the expansion attribute.
1. Method 1
Select B2. In the right-hand pane, select [Vertical].
2. Method 2
Double click B2 to bring up the [Data Column] window. Select [Vertical] and click [OK].
3. A down arrow exists in the upper left of B2
It indicates that the attribute is set as vertical expansion.
4. The preview effect
Note: Vertical expansion: When being previewed, each value in the same data column occupies a unique cell and the cells align vertically.
III. Horizontal expansion
1. Select B2. In the right-hand pane, select [Horizontal]
2. A right arrow exists in the upper left of B2
It indicates that the attribute is set as horizontal expansion.
3. The preview effect
Note:
Horizontal expansion: When being previewed, each value in the same data column occupies a unique cell and the cells align horizontally.
The default preview mode is [Pagination Preview], and content that exceeds the page width is displayed in the next page.
Left Parent Cell and Upper Parent Cell
1) If data columns from the same dataset are inserted into several cells and these cells are assigned with the attribute of cell expansion, you can set one cell as the parent cell and another as the child cell.
2) The assiginment of parent cell control the way data are displayed when previewing the report.
3) Usually, the attributes of parent cell and cell expansion are used to group data, and you will see the grouping effect in this article.
You will learn |
---|
|
I. Left parent cell
1. Create a new dataset [ds1]
1) Create a new DB query dataset.
2) SQL statement: SELECT DISTINCT Region, Salesperson From Sales_Volume
2. Drag data columns into cells
1) Drag [Region] into B2 and [Salesperson] into C2.
2) B2 and C2: Expand vertically.
3. The left parent cell of C2: Default
1) Default left parent cell: refers to a horizontal/vertical extension cell adjacent to the cell on the left by default.
2) Click C2 and a blue down arrow will show in B2, indicating that B2 is set as the left parent cell of C2.
3) Double click C2 and the Data Column setup panel will show that B2 is set as the left parent cell of C2.
4. Align B2 and C2 to the middle and add borders
5. Preview the effect
1) [Region] and [Salesperson] expand vertically concurrently.
2) There is a one-to-one correspondence between [Salesperson] and [Region] and cells with the same [Region] value are automatically merged, showing the effect of auto grouping of salesperson by region.
6. The left parent cell of C2: Null
7. Preview the effect
1) [Region] and [Salesperson] expand vertically independently.
2) There is no one-to-one correspondence between [Salesperson] and [Region], thus no grouping effect.
II. Upper parent cell
1. Create a new dataset [ds1]
1) Create a new DB query dataset.
2) SQL statement: SELECT DISTINCT Region, Salesperson From Sales_Volume.
2. Drag data columns into cells
1) Drag [Region] into B2 and [Salesperson] into B3.
2) B2 and B3: Expand horizontally.
3. The upper parent cell of B3: Default
1) Default upper parent cell: refers to a horizontal/vertical extension cell adjacent to the cell on the top by default.
2) Click B3 and a blue down arrow will show in B2, indicating that B2 is set as the upper parent cell of B3.
3) Double click B3 and the Data Column setup panel will show that B2 is set as the upper parent cell of B3.
4. Align B2 and B3 to the middle and add borders
5. Preview the effect of [Data Analysis]
6. Preview the effect
1) [Region] and [Salesperson] expand horizontally concurrently.
2) There is a one-to-one correspondence between [Salesperson] and [Region] and cells with the same [Region] value are automatically merged, showing the effect of auto grouping of salesperson by region.
7. The upper parent cell of B3: Null
8. Preview the effect of [Data Analysis]
1) [Region] and [Salesperson] expand horizontally independently.
2) There is no one-to-one correspondence between [Salesperson] and [Region], thus no grouping effect.
III. Custom setting
1. Create a new dataset [ds1]
1) Create a new DB query dataset.
2) SQL statement: SELECT DISTINCT Region, Salesperson From Sales_Volume
2. Drag data columns into cells
1) Drag [Region] into B2 and [Salesperson] into C3.
2) B2 and C3: Expand vertically.
3. The parent cell of C3: Custom
1) Left parent cell: Custom
2) Click the mouse button and click B2.
4. Align B2 and C3 to the middle, add borders and preview the effect
Horizontally and Vertically Expansible
A typical usage scenario: One cell is inserted with text as the title. In the mean time, the cell below is inserted with a data column and is assigned with the attribute of horizontal expansion, yet the width after expansion is unknown. If the title cell is set as horizontally expansible, then in the preview, its cell width will be broadened automatically to align with the data below.
You will learn |
---|
|
I. Horizontally expansible
1. Create a new dataset [ds1]
1) Create a new DB query dataset.
2) Drag the table [Sales_Volume] into the DB query.
2. Drag data columns into cells
1) Drag the data column [Salesperson] into B2.
2) Set B2 as horizontal alignment and add borders. Select Horizontal as the Expand Direction in the [Cell Attributes] > [Expand] panel.
3. Add a title
1) Input text in B1: Title.
2) Set B1 as horizontal alignment and fill it with gray.
3) Maintain the default expansion attributes:
Expand Direction: No Expansion
Advanced: Horizontally
4. Select [Data Analysis] preview
5. Preview the effect
1) The data column [Salesperson] expands horizontally.
2) The title cell is set as [No Expansion], but expands as the data column below expands horizontally in the preview.
6. Cancel the [Horizontally Expansible] attribute of B1
7. Preview the effect of [Data Analysis]
The title does not expand as the data column below expands horizontally.
II. Vertically expansible
1. Create a new dataset [ds1]
1) Create a new DB query.
2) Input the SQL statement: SELECT * FROM Sales_VolumeWHERE Salesperson = "Sun Lin"
2. Drag data columns into cells
1) Drag the data column [Product] into B2 and the data column [Sales_Volume] into C2.
2) B2 and C2: set as center alignment, add borders and select Vertical as the Expand Direction in the Cell Attributes>Expand panel.
3. Add data description
1) Input text in A2: Product Sales.
2) Set A2 as center alignment, add borders and fill it with gray.
3) Maintain the default expansion attributes:
Expand Direction: No Expansion
Advanced: Vertically
4. Preview the effect
1) Data columns [Product] and [Sales_Volume] expand vertically.
2) The data description cell is set as [No Expansion], but expands as the data column on the right expands vertically in the preview.
5. Cancel the [Vertically Expansible] attribute of A2
6. Preview the effect
Data description does not expand as the data column on the right expands vertically.