Dela via


2.2.7.2 ALTROW

Token Stream Name:

 ALTROW

Token Stream Function:

Used to send a complete row of total data, where the data format is provided by the ALTMETADATA token.

Token Stream Comments:

  • The token value is 0xD3.

  • The ALTROW token is similar to the ROW_TOKEN, but also contains an Id field. This Id matches an Id given in ALTMETADATA (one Id for each SQL statement). This provides the mechanism for matching row data with correct SQL statements. ALTROW and the corresponding ALTMETADATA MUST be in the same result set.

  • Note ALTROW was deprecated in TDS 7.4.

Token Stream-Specific Rules:

 TokenType        =   BYTE
 Id               =   USHORT
  
 Data             =   TYPE_VARBYTE
  
 ComputeData      =   Data

Token Stream Definition:

 ALTMETADATA      =   TokenType
                      Id
                      1*ComputeData

The ComputeData element is repeated Count times, where Count is specified in ALTMETADATA_TOKEN.

Token Stream Parameter Details:

 Parameter

 Description

TokenType

ALTROW_TOKEN<40>

Id

The Id of the SQL statement that generates totals to which the total column formats apply. This Id lets the client correctly interpret later ALTROW data streams.

Data

The actual data for the column. The TYPE_INFO information describing the data type of this data is given in the preceding COLMETADATA_TOKEN, ALTMETADATA_TOKEN, or OFFSET_TOKEN.