Enterprise Edition Home | Express Edition Home | Previous Page | Next Page   SQL Statements >

SAVE EXTERNAL DIRECTIVES

Use the SAVE EXTERNAL DIRECTIVES statement to create external optimizer directives for a specified query, and save the directives in the database. These directives are applied automatically to subsequent instances of the same query.

Only Dynamic Server supports this statement, which is an extension to the ANSI/ISO standard for SQL.

Syntax

Read syntax diagramSkip visual syntax diagram                             .-,---------.
                             V           |
>>-SAVE EXTERNAL DIRECTIVES----directive-+--+-ACTIVE----+------->
                                            +-INACTIVE--+
                                            '-TEST ONLY-'
 
>--FOR--query--------------------------------------------------><
 

Element Description Restrictions Syntax
directive Optimizer directive valid for query Must be valid for query Optimizer Directives
query Text of a valid SELECT statement NULL string is not valid SELECT

Usage

SAVE EXTERNAL DIRECTIVES associates one or more optimizer directives with a query, and stores a record of this association in the sysdirectives system catalog table, for subsequent use with queries that match the specified query string. This statement establishes an association between the list of optimizer directives and the text of a query, but it does not execute the specified query.

Only the DBA or user informix can execute SAVE EXTERNAL DIRECTIVES. Optimizer directives that it stores in the database are called external directives.

Enterprise Edition Home | Express Edition Home | [ Top of Page | Previous Page | Next Page | Contents | Index ]