Get Position (22)
The Get Position operation (B_GET_POSITION) returns the physical 4-byte position of the current record. Get Position fails if there is no established physical currency when you issue the operation. Once you determine a record’s position (address), you can use the Get Direct/Record operation (23) to retrieve that record directly by its physical location in the file. The transactional interface does not perform any disk I/O to process a Get Position request.
Parameter
 
Prerequisites
Procedure
1
2
3
4
Result
If the Get Position operation is successful, the transactional interface returns the position of the record in the Data Buffer. The position is a 4-byte binary value (most significant word first) that indicates the record’s offset (in bytes) into the file. The transactional interface also sets the Data Buffer Length to 4 bytes.
If the Get Position operation is unsuccessful, the transactional interface returns one of the following status codes:
Positioning
The Get Position operation has no effect on positioning.