The ESQL/C preprocessor
- In stage one, the HCL
OneDB ESQL/C preprocessor
performs the following steps:
- Incorporates header files into the source file when it processes all include directives ($include and EXEC SQL include statements)
- Creates or removes compile-time definitions when it processes all define ($define and EXEC SQL define) and undef ($undef and EXEC SQL undef) directives
- In stage two, the HCL
OneDB ESQL/C preprocessor
processes any conditional compilation directives (ifdef, ifndef, else, elif, endif)
and translates embedded SQL statements to HCL
OneDB ESQL/C function
calls and special data structures.
Stages 1 and 2 mirror the preprocessor and compiler stages of the C compiler. Successful completion of the preprocessing step yields a C source file (.c extension). For information about command-line options that affect the preprocessing step, see Options that affect preprocessing.
- The file name of the HCL OneDB ESQL/C source file has the .ec or the .ecp.
- The INFORMIXDIR and PATH environment
variables are set correctly.
If the INFORMIXDIR environment variable is not set in the command window or in the Windows™ Registry, it is set internally to the location of the HCL® OneDB Client SDK dynamically linked libraries.
If the INFORMIXDIR environment variable is not set in UNIX™, an error is returned when compiling any HCL OneDB Client Software Development Kit (Client SDK) application.
For information about how to set the INFORMIXDIR and PATH variables, see the HCL OneDB Client Products Installation Guide for your operating system.
The C code that the HCL OneDB ESQL/C preprocessor generates might change from one release of the product to the next. Therefore, do not design HCL OneDB ESQL/C programs that depend on how HCL OneDB implements the functionality and features of the product in the C code that the HCL OneDB ESQL/C preprocessor generates. Instead, develop your programs with the functionality and features of the product that this publication describes.