Generally, you also set applicable preprocessor compiler directive options when you specify the preprocessor; however, you can use a combination of methods at your preference. The order in which the COBOL compiler calls the preprocessor depends on where you specify it. We provide several alternatives:
- In the
Enterprise Developer IDE
- You can specify an ESQL preprocessor and its applicable compiler directive options on the
SQL tab of your project properties. Do this when your primary method of compilation is building a program or application from the IDE.
- On the Command Line
- When compiling from the command line, you can specify your ESQL preprocessor and its directives in the sequence of compiler directives specified as arguments to the
cobol command.
- In a Directives File
- You can specify your ESQL preprocessor and its directives in the
cobol.dir system-wide directives file and/or in a user directives file.
- Embedded in the Program
- You can also specify a preprocessor on the program level by embedding a $SET statement into the program itself. Use this method only when the program requires a preprocessor different from other programs in an application.
For details on setting specific
ESQL preprocessors, see
Related concepts below.