Striim 3.9.4 / 3.9.5 documentation

Functions for HP NonStop transaction IDs

function

description

notes

NSK_CNVT_TXNID_TO_UNSIGNED(txnid)

returns the unsigned representation of a NonStop system transaction ID

While Striim always represents a NonStop system transaction ID as an unsigned value, other software, such as Golden Gate, can represent NonStop system transaction IDs as signed values. When the NonStop system number is larger than 126, representing it as signed yields a negative value, which will not be the same as the unsigned value of the same transaction ID. This function converts a negative transaction ID's value to the equivalent positive value, and leaves a positive transaction ID's value unchanged.

It is not necessary to use NSK_CNVT_TXNID_TO_UNSIGNED to convert transaction IDs that will be passed to either NSK_TXNS_ARE_SAME or NSK_TXN_STRING, since they already do the conversion to unsigned. NSK_CNVT_TXNID_TO_UNSIGNED is provided in case you have some other reason to make sure a transaction ID is represented as unsigned.

NSK_TXN_STRING(txnid,systemname)

returns HPE's human-readable form for a transaction ID. txnid is the value of the TxnID field of a WAEvent, and systemname is the TxnSystemName field of the same WAEvent.

This function is useful only if you want to display NonStop system transaction IDs in the same format that HPE's software displays them. That could be helpful if you have to investigate the history of the transaction on the NonStop system. See HP NonStop reader WAEvent fields for an example.

NSK_TXNS_ARE_SAME(txnid1,txnid2)

returns true if the two string arguments identify the same transaction, regardless of differences in how the transaction IDs are represented

Can be used for any comparison of transaction IDs from NonStop systems, but really only needed when comparing transaction IDs from NonStop systems that came to the TQL application via different software products. For example, one transaction ID came via an HPNonStopSQLMXReader adapter and the other came from Golden Gate's Extract, and then only if some of the NonStop systems have system numbers greater than 126. Striim Source adapters always interpret transaction IDs from NonStop systems as unsigned 64-bit values, while other software might interpret the transaction IDs as signed 64-bit values, giving different representations of the same transaction ID.