REPOSITION-TO-ROWID( ) method

Moves a query object's result list pointer to the row corresponding to the specified ROWID or ROWIDs.

To reposition to a particular row when the query is a join, supply the ROWID values of the buffers that correspond to the desired row.

Return type: LOGICAL

Applies to: Query object handle

Syntax

REPOSITION-TO-ROWID (
  {     rowid1 [ , rowid2 ] [ , tenant-expression ] 
     |  rowid-array 
  }
rowid1 [ , rowid2 ] ...
Expressions of type ROWID representing the ROWID of the first buffer, the ROWID of the second buffer, and so on, in the join. The maximum number of expressions is 18. If an expression contains the Unknown value (?), the AVM evaluates but ignores subsequent expressions.
rowid-array
An array of 18 or fewer elements, where each element is of type ROWID and represents the rowid of a buffer. If an element contains the Unknown value (?), the AVM evaluates but ignores subsequent elements.
tenant-expression
This parameter is useful only for a multi-tenant database, and primarily one with a connection identity that has super tenant access. If the user has a super-tenant connection identity and you do not specify this parameter, the query repositions to data owned by the effective tenant. If you do specify this parameter, the query repositions to data owned by the regular tenant identified by tenant-expression.

If the user has a regular-tenant connection identity, and you specify this parameter, tenant-expression must match the tenancy of the connection identity. Otherwise, the statement raises ERROR.

If tenant-expression evaluates to an integer, the value must be a valid tenant ID for a regular tenant or zero (0) for the default tenant. If tenant-expression evaluates to a character string, the value must be a valid tenant name for a regular or "Default" for the default tenant. Otherwise, the statement raises ERROR.

If you pass tenant-expression and any of the ROWID values belong to a table that is not multi-tenant enabled, ABL raises a run-time error.

Notes

See also

REPOSITION statement, REPOSITION-FORWARD( ) method, REPOSITION-TO-ROW( ) method