Striim 4.0.4 documentation

SQL Server readers WAEvent fields

The output data type for MS SQL Reader and MSJet is WAEvent. The elements are:

metadata: a map including:

  • BeginLsn (MSJet only): LSN of Begin operation for the transaction

  • BeginTimestamp (MSJet only): timestamp of Begin operation for the transaction

  • CommitLsn (MSJet only): LSN of Commit operation for the transaction

  • CommitTimestamp (MSJet only): timestamp of Commit operation for the transaction

  • OperationName: INSERT, UPDATE, or DELETE

    MSJet only: When schema evolution is enabled, OperationName for DDL events will be Alter, AlterColumns, Create, or Drop. This metadata is reserved for internal use by Striim and subject to change, so should not be used in CQs, open processors, or custom Java functions.

  • PartitionId (MSJet only): the partition from which the data was read

  • PK_UPDATE:

    • MS SQL Reader: for UPDATE only, true if the primary key value was changed, otherwise false

    • MSJet: field not included (see limitations in SQL Server)

  • SEQUENCE: LSN of the operation

  • TableName: fully qualified name of the table . It is present but null for key-sequenced files and key-sequenced tables that have a user-defined primary key.

  • TimeStamp (MS SQL Reader only): timestamp from the CDC log. By default, values are included only for the first record of a new transaction (for more details, see FetchTransactionMetadata in MSSQLReader properties).

  • TransactionName: name of the transaction

  • TxnID: transaction ID. When using MS SQL Reader, by default, values are included only for the first record of a new transaction (for more details, see FetchTransactionMetadata in MSSQLReader properties).

To retrieve the values for these fields, use the META() function. See Parsing the fields of WAEvent for CDC readers.

data: an array of fields, numbered from 0, containing:

  • for an INSERT or DELETE operation, the values that were inserted or deleted

  • for an UPDATE, the values after the operation was completed

To retrieve the values for these fields, use SELECT ... (DATA[]). See Parsing the fields of WAEvent for CDC readers.

before (for UPDATE operations only): the same format as data, but containing the values as they were prior to the UPDATE operation

dataPresenceBitMap, beforePresenceBitMap, and typeUUID are reserved and should be ignored.