共用方式為


CalculationItem Class

Definition

A Tabular Calculation Item.

public sealed class CalculationItem : Microsoft.AnalysisServices.Tabular.NamedMetadataObject
type CalculationItem = class
    inherit NamedMetadataObject
Public NotInheritable Class CalculationItem
Inherits NamedMetadataObject
Inheritance

Remarks

This metadata object is only supported when the compatibility level of the database is at 1470 or above.

Constructors

CalculationItem()

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

Properties

CalculationGroup

A reference to a CalculationGroup object that owns this CalculationItem.

Description

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

ErrorMessage

The string that explains the error state associated with the CalculationItem. It is set by the engine only when the state of the Expression is one of these three values: SemanticError, DependencyError or SyntaxError.

Expression

The DAX expression that is evaluated for this CalculationItem.

FormatStringDefinition

A reference to a FormatStringDefinition object owned by this CalculationItem.

IsRemoved

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

(Inherited from MetadataObject)
Model

Gets the Tabular model that contains this object.

(Inherited from MetadataObject)
ModifiedTime

The time that the object was last modified.

Name

Gets or Sets the Name of this object.

ObjectType

Gets the type of the object.

Ordinal

The zero-based ordinal value associated with a Calculation Item.

Parent

Parent object, null for Model objects.

State

Provides information on the state of the Expression. Possible values and their interpretation are as follows. Ready (1) The Expression is queryable and has up-to-date data. SemanticError (5) The Expression has a semantic error. DependencyError (7) A dependency associated with this Expression is in an error state (SemanticError, EvaluationError, or DependencyError). SyntaxError (9) The Expression has a syntax error.

Methods

Clone()

Creates a new, full copy of a CalculationItem object.

CopyFrom(CalculationItem)
Obsolete.

Deprecated. Use CopyTo method instead.

CopyTo(CalculationItem)

Copies a CalculationItem object to the specified object.

Rename(String)
Obsolete.

Deprecated. Use RequestRename method instead.

RequestRename(String)

Request rename of this object.

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