Run a program with embedded SQL: Override considerations

You can use overrides (specified by the OVRDBF command) to direct a reference to a different table or view or to change certain operational characteristics of the program or SQL Package.

The following parameters are processed if an override is specified:

All other override parameters are ignored. Overrides of statements in SQL packages are accomplished by doing both of the following:

  1. Specifying the OVRSCOPE(*JOB) parameter on the OVRDBF command
  2. Sending the command to the application server by using the Submit Remote Command (SBMRMTCMD) command

To override tables and views that are created with long names, you can create an override using the system name that is associated with the table or view. When the long name is specified in an SQL statement, the override is found using the corresponding system name.

An alias is actually created as a DDM file. You can create an override that refers to an alias name (DDM file). In this case, an SQL statement that refers to the file that has the override actually uses the file to which the alias refers.

Related information
Database programming
Database file management