Association records are rows that an Administrator can insert into SQL statements when needed. The following example shows an association-record row that can be used as a query directive.
save external directives {+INDEX(t1,i11)} active for select {+INDEX(t1, i2) } c1 from t1 where c1=1;
id 16
query select {+INDEX(t1, i2) } c1 from t1 where c1=1
directive INDEX(t1,i11)
directivecode BYTE value
active 1 hashcode -589336273
SAVE EXTERNAL DIRECTIVES directives [ACTIVE/INACTIVE/TEST ONLY]
FOR Select/* INDEX( table1 , index1 )*/ col1 , col2
From table1, table 2
Where table1.col1+table2.col1
The information in directives must be in the same format within comments exactly as the directive would appear in SELECT, UPDATE, and DELETE statements. (See the IBM Informix: Guide to SQL Syntax for more information on SAVE EXTERNAL DIRECTIVES).