Dela via


CalculatedColumn Class

Definition

Represents a column that is based on a DAX expression in a Table that also contains DataColumns and a RowNumberColumn. A CalculatedColumn can also be added to a calculated table.

public class CalculatedColumn : Microsoft.AnalysisServices.Tabular.Column
type CalculatedColumn = class
    inherit Column
Public Class CalculatedColumn
Inherits Column
Inheritance

Constructors

CalculatedColumn()

Create a new instance of the CalculatedColumn class with default settings..

Properties

Alignment

Specifies the text alignment of the column in report visualizations. The possible values are Default (1), Left (2), Right (3), Center (4).

(Inherited from Column)
AlternateOf

Defines the AlternateOf reference source BaseTable or BaseColumn, and the Summarization.

(Inherited from Column)
Annotations

Gets the collection object of all annotations in the current Column.

(Inherited from Column)
AttributeHierarchy

A reference to an AttributeHierarchy object associated with this ColumnOrigin object.

(Inherited from Column)
ChangedProperties

Gets the collection object of all changedproperties in the current Column.

(Inherited from Column)
DataCategory

Specifies the type of data contained in the column so that you can add custom behaviors based on column type. There are 248 possible values. The first ten are Invalid (-1), All (1), Regular (2), Image (3), ImageBMP (4), ImageGIF (5), ImageJPG (6), ImagePNG (7), ImageTIFF (8), ImageURL (9), Id (10). For the rest, please refer to the MS-SSAS-T SQL Server Analysis Services Tabular Protocol documentation on MSDN.

(Inherited from Column)
DataType

For a DataColumn, specifies the data type. See https://msdn.microsoft.com/library/gg492146.aspx for a list of supported data types.

(Inherited from Column)
Description

The description of the column, visible to developers at design time and to administrators in management tools, such as SQL Server Management Studio.

(Inherited from Column)
DisplayFolder

Defines the display folder for the column, for use by clients.

(Inherited from Column)
DisplayOrdinal

Indicates the visual position of the column, defined as a relative ordering rather than a strict ordering (example: 10, 20, 40, 50). It allows client applications to maintain a consistent column position.

(Inherited from Column)
EncodingHint

This property allows an encoding hint to be specified for the column. A numeric column may use either value-based encoding or hash-based encoding. Usually the server will automatically attempt detect which encoding to use, but re-encoding may occur later. This property allows hinting to the server that it should start with a different encoding type.

(Inherited from Column)
ErrorMessage

A string that explains the error state associated with the current object. It is set by the engine only when the state of the object is one of these three values: SemanticError, DependencyError, or EvaluationError. It is applicable only to columns of the type Calculated or CalculatedTableColumn. It will be empty for other column objects.

(Inherited from Column)
Expression

The DAX expression that is evaluated for the calculated column.

ExtendedProperties

Gets the collection object of all extendedproperties in the current Column.

(Inherited from Column)
FormatString

A string that specifies the format of the column contents.

(Inherited from Column)
IsAvailableInMDX

A boolean value that indicates whether the column can be excluded from usage in MDX query tools. False if the column can be excluded from usage in MDX query tools; otherwise true.

(Inherited from Column)
IsDataTypeInferred

A boolean value indicating whether the datatype is inferred.

(Inherited from Column)
IsDefaultImage

A boolean value that indicates whether this column is returned as the DefaultImage property in CSDL.

(Inherited from Column)
IsDefaultLabel

A boolean value that indicates whether this column is included in the DisplayKey element in CSDL.

(Inherited from Column)
IsHidden

A boolean value that indicates whether a column is treated as hidden by client visualization tools. True if the column is treated as hidden; otherwise false.

(Inherited from Column)
IsKey

A boolean value that indicates whether the column is a key of the table. True if the column is a key of the table; otherwise false.

(Inherited from Column)
IsNullable

If false, the column cannot contain nulls. Even if true, it may still not allow nulls if it's a key column.

(Inherited from Column)
IsRemoved

A Boolean specifying whether this object was removed from an object tree.

(Inherited from MetadataObject)
IsUnique

A boolean value that indicates whether the column contains only unique values. True if the values are unique; otherwise false.

(Inherited from Column)
KeepUniqueRows

Specifies the grouping behavior used for building a hierarchy. True groups by entity key. False groups by value.

(Inherited from Column)
LineageTag

A tag that represents the lineage of the object.

(Inherited from Column)
Model

Gets the Tabular model that contains this object.

(Inherited from MetadataObject)
ModifiedTime

The time that the object was last modified.

(Inherited from Column)
Name

Gets or sets the name of a column in a Tabular model.

(Inherited from Column)
ObjectType

Gets the type of the object.

(Inherited from Column)
Parent

Parent object, null for Model objects.

(Inherited from Column)
RefreshedTime

The time that the object was last refreshed.

(Inherited from Column)
RelatedColumnDetails

A reference to a RelatedColumnDetails object associated with this Column object.

(Inherited from Column)
SortByColumn

Indicates that the column defining this property will be sorted by the values of the column referenced by this property.

(Inherited from Column)
SourceLineageTag

A tag that represents the lineage of the source for the object.

(Inherited from Column)
SourceProviderType

The original data type of the column as defined in the language of the data source. This data type is used to generate queries directly against the data source, for example in DirectQuery mode.

(Inherited from Column)
State

Enumerates the state of the column. Possible values include the following. Ready (1) The column is queryable and has up-to-date data. NoData (3) The column is queryable but has no data. This state is applicable only to columns of the type Data. CalculationNeeded (4) The column is not queryable and needs to be refreshed (that is, recalculated) to become functional. This state applies only to columns of the type Calculated or CalculatedTableColumn. SemanticError (5) The column is in an error state because of an invalid expression. The column is not queryable. This state applies only to columns of the type Calculated or CalculatedTableColumn. EvaluationError (6) The column is in an error state because of an error during expression evaluation. The column is not queryable. This state applies only to columns of the type Calculated or CalculatedTableColumn. DependencyError (7) The column is in an error state because some of its calculation dependencies are in an error state. The column is not queryable. This state applies only to columns of the type Calculated or CalculatedTableColumn. Incomplete (8) Some parts of the column have no data, and the column needs to be refreshed to bring the data in. The column is queryable. This state applies only to columns of the type Data. SyntaxError (9) The column is in an error state because of a syntax error in its expression. The column is not queryable. This state applies only to columns of the type Calculated.

(Inherited from Column)
StructureModifiedTime

The time that the structure of the object was last modified.

(Inherited from Column)
SummarizeBy

A value indicating the default function, if any, used to aggregate this field. The possible values are Default (1), None (2), Sum (3), Min (4), Max (5), Count (6), Average (7), DistinctCount (8). If unspecified, Default is assumed for numeric fields, None for all other fields.

(Inherited from Column)
Table

A reference to a Table object that owns this Column.

(Inherited from Column)
TableDetailPosition

Determines whether you can place this column in the DefaultDetails collection of the Table. This collection is an ordered set of Column types. A positive value indicates participation in the collection. The collection is sorted in ascending order of this element. The DefaultDetails collection is returned as part of the CSDL metadata returned by the DISCOVER_CSDL_METADATA operation.

(Inherited from Column)
Type

Specifies the data binding. Values include Data (1) where the contents of this column come from a DataSource, Calculated (2) where the contents are computed from an expression after the Data columns have been populated, RowNumber (3) where the column is an internal column representing the row number, or CalculatedTableColumn (4) where tables that are based on a calculated expression will automatically infer and generate the columns in the table.

(Inherited from Column)
Variations

Gets the collection object of all variations in the current Column.

(Inherited from Column)

Methods

Clone()

Creates a new, full copy of a Column object.

(Inherited from Column)
CopyFrom(Column)
Obsolete.

Deprecated. Use CopyTo method instead.

(Inherited from Column)
CopyTo(Column)

Copies a Column object to the specified object.

(Inherited from Column)
Rename(String)
Obsolete.

Deprecated. Use RequestRename method instead.

(Inherited from Column)
RequestRename(String)

Request rename of this object.

(Inherited from Column)
Validate()

This API supports the product infrastructure and is not intended to be used directly from your code. Microsoft Internal Use Only.

(Inherited from MetadataObject)

Applies to