ITableValueColumnDefinition
Home > @gooddata/sdk-ui > ITableValueColumnDefinition
ITableValueColumnDefinition type
This API is provided as an alpha preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
Defines columns that contain actual data values (values and subtotals).
**What it does:** These columns show your actual data - sales numbers, counts, percentages, etc. The columnScope
tells you exactly what this column represents.
**When it's created:** The system creates these based on your column headers. Here's how:
**Simple case - just measures:**
| Country | Sales | Profit | <- Sales and Profit are value columns
|---------|-------|--------|
| USA | 100 | 20 |
**Pivoted case - attributes + measures in columns:**
| Country | East Sales | East Profit | West Sales | West Profit |
|---------|------------|-------------|------------|-------------|
| USA | 100 | 20 | 150 | 30 |
**Transposed case - measures in rows, attributes in columns:**
| Country | Measure | East | West |
|---------|---------|------|------|
| USA | Sales | 100 | 150 |
| USA | Profit | 20 | 30 |
Signature:
export type ITableValueColumnDefinition = {
type: "value";
columnIndex: number;
columnHeaderIndex: number;
columnScope: ITableDataHeaderScope[];
} & (/**
* Handles case, when pivoting and measures are in rows.
*/ {
isEmpty: false;
isTransposed: true;
attributeHeader: IResultAttributeHeader;
attributeDescriptor: IAttributeDescriptor;
}
/**
* Handles standard pivoting case without transposition.
*/
| {
isEmpty: false;
isTransposed: false;
measureHeader: IResultMeasureHeader;
measureDescriptor: IMeasureDescriptor;
}
/**
* Handles case, when pivoting, but there are no measures.
*/
| {
isEmpty: true;
isTransposed: false;
attributeHeader: IResultAttributeHeader;
attributeDescriptor: IAttributeDescriptor;
});
References: ITableDataHeaderScope, IResultAttributeHeader, IAttributeDescriptor, IResultMeasureHeader, IMeasureDescriptor