sp_iqmpxgetconnversion procedure

Function

Displays the version number for a specified connection.

Syntax

call sp_iqmpxgetconnversion ( )

Usage

On a multiplex query server, returns in an UNSIGNED BIGINT the version number that the current connection uses for the current transaction. On a write server, always returns 0.

The version number is a database-wide monotonically-increasing integer that increases any time the write server commits new data in the IQ Main store.

Description

This procedure lets you determine versions across connections on one or more multiplex query servers in a multiplex environment.

For instance, assume that two different connections are made to query servers at nearly the same time, and you need to coordinate by SELECT statements between the two connections so that they are using the same version of the data. If any transaction committed between the moment of the first and the second connections, they see two different versions.

This procedure lets you determine whether both connections are using the same version of the data.

You cannot determine whether write server connections see the same version of the data.