SQLCODE in pure C modules

To return the same values that the SQLCODE status variable in modules returns, you can use SQLCODE in pure C modules (modules with the .c extension) that you link to the program. To use SQLCODE in a pure C module, declare SQLCODE as an external variable, as follows:
extern int4 SQLCODE;