Open System Services System Calls Reference Manual (G06.28+)

SPT_READUPDATEX(2) OSS System Calls Ref
erence Manual
For programming information about the READUPDATEX procedure, see the
Enscribe
Programmers Guide and the Guardian Programmers Guide.
Considerations
Buffer use SPT_READUPDATEX() is intended for use with 32-bit extended addresses.
Therefore, the data buffer for SPT_READUPDATEX() can be either in the
callers stack segment or any extended data segment.
Random processing and positioning
A call to SPT_READUPDATEX() returns the record from the current position
in the le. Because SPT_READUPDATEX( ) is designed for random process-
ing, it cannot be used for successive positioning through a subset of records as
the SPT_READX() function does. Rather, SPT_READUPDATEX() reads a
record after a call to the Guardian POSITION or KEYPOSITION procedure, in
anticipation of a subsequent update through a call to the Guardian WRITEUP-
DATEX procedure.
Calling SPT_READUPDATEX() after SPT_READX()
A call to SPT_READUPDATEX() after a call to SPT_READX(), without
intermediate positioning, returns the same record as the call to SPT_READX( ).
Waited SPT_READUPDATEX()
If a waited SPT_READUPDATEX() is executed, the count_read parameter
indicates the number of bytes actually read.
Nowait I/O and SPT_READUPDATEX()
If a nowait SPT_READUPDATEX() is executed, count_read has no meaning
and can be omitted. The count of the number of bytes read is obtained when the
I/O operation completes through the count_transferred parameter of the Guar-
dian AWAITIOX procedure. The SPT_READUPDATEX() function must com-
plete with a corresponding call to the Guardian AWAITIOX procedure when
used with a le that is opened nowait.
Default locking mode action
If the default locking mode is in effect when a call to SPT_READUPDATEX()
is made to a locked le or record, but the lenum of the locked le differs from
the lenum in the call, the caller of SPT_READUPDATEX( ) is suspended and
queued in the locking queue behind other processes attempting to access the le
or record.
Use on OSS objects
This procedure operates only on Guardian objects. If an OSS le is specied, Guardian le-
system error 2 occurs.
RETURN VALUES
The SPT_READUPDATEX() function returns 0 (zero) upon successful completion. Otherwise,
this function returns a nonzero Guardian le-system error number that indicates the outcome of
the operation.
For information about Guardian le-system error numbers, see the Guardian Procedure Errors
and Messages Manual.
7244 Hewlett-Packard Company 527186-005