Enabling external directives
After you create and save external directives, you must set the configuration parameter and environmental variable that enable the directives. The database server searches for a directive for a query only if the external directives are set on both the database server and the client.
Enable the directive by using a combination of the EXT_DIRECTIVES configuration parameter, which is in the ONCONFIG file, and the IFX_EXTDIRECTIVES client-side environment variable.
Value | Explanation |
---|---|
0 (default) |
Off. The directive cannot be enabled, even if IFX_EXTDIRECTIVES is enabled. |
1 |
On. The directive can be enabled for a session if IFX_EXTDIRECTIVES is enabled. |
2 |
On. The directive can be used even if IFX_EXTDIRECTIVES is not enabled. |
You can also use the EXTDIRECTIVES option of the SET ENVIRONMENT statement to enable or disable external directives during a session. What you specify with the EXTDIRECTIVES option overwrites the external directive setting that is specified in the EXT_DIRECTIVES configuration parameter in the ONCONFIG file.
To overwrite the value for enabling or disabling the external directive in the ONCONFIG file:
- To enable the external directives during a session, specify
1
,on
, orON
as the value for SET ENVIRONMENT EXTDIRECTIVES. - To disable the external directives during a session, specify
0
,off
, orOFF
as the value for SET ENVIRONMENT EXTDIRECTIVES.
To enable the default values specified in the EXT_DIRECTIVES configuration parameter and in the client-side IFX_EXTDIRECTIVES environment variable during a session, specify DEFAULT as the value for the EXTDIRECTIVES option of the SET ENVIRONMENT statement.
The explain output file specifies whether external directives are in effect.