3. Embedded SQL for COBOL : Preprocessor Operation : How to Incorporate Ingres into the Micro Focus RTS—UNIX
 
Share this page                  
How to Incorporate Ingres into the Micro Focus RTS—UNIX
Before you can run any embedded SQL/COBOL program, you must create a new Micro Focus Runtime System (or RTS), linked with the Ingres libraries. This will enable your embedded SQL/COBOL programs to access the necessary Ingres routines at runtime.
If you are unsure whether your COBOL RTS is linked to the Ingres libraries, you can perform a simple test. Preprocess, compile, and run a simple ESQL/COBOL program that connects and disconnects from Ingres. For example, the simple test file test.scb could include the lines:
EXEC SQL CONNECT dbname END-EXEC.
EXEC SQL DISCONNECT END-EXEC.
If your COBOL RTS is not linked to the Ingres libraries, you will receive the COBOL runtime error number 173 when you run the program:
esqlcbl test.scb
cob test.cbl
cobrun test
    Load error: file 'IIsqConnect'
    error code: 173, pc=1A, call=1, seg=0
    173 Called program file not found in
         drive/directory