SQL Programming Manual for TAL
System Procedures
HP NonStop SQL Programming Manual for TAL—527887-001
4-8
SQLCAGETINFOLIST
first^flg input
INT
specifies whether the first or the last error is set in the SQLCA. You can set first^flg
as follows:
Nonzero value (or omitted) First error
0 Last error
Guidelines
Follow these guidelines when you call the SQLCAFSCODE procedure:
•
If the SQLCA is full when a file-system error occurs, the error is lost and cannot be
returned by SQLCAFSCODE.
•
Use SQLCAFSCODE to get the Guardian or file-system error code that occurs for
an SQL operation. You can then determine the action your program should take,
depending on this error rather than on the SQL error.
This example shows a call to the SQLCAFSCODE procedure:
INT fserr; !Guardian 90 or file-system error
EXEC SQL INCLUDE SQLCA;
...
fserr := SQLCAFSCODE (sqlca);
! Check fserr to determine the error
...
SQLCAGETINFOLIST
The SQLCAGETINFOLIST procedure returns error or warning information that
NonStop SQL sets in the SQLCA structure. You specify a list of numbers, called item
codes, to select this information, and then SQLCAGETINFOLIST returns the
information to a structure you define. By using item codes, you can specify the exact
information you want SQLCAGETINFOLIST to return.
This information can be from these subsystems or system components:
•
NonStop SQL
•
FASTSORT program (SORTPROG process)
•
Sequential I/O (SIO) procedures
•
File system
•
NonStop Kernel operating system