


The name of a structure or array variable can also be specified as '!var', e.g., in the <select list> of the select statement. This has the same effect as the explicit specification of the individual components in their order of definition. Instead of the exclamation mark, the character tilde ('~var') may also be used. "<[authid].tablename.>" can also be specified before "!<var>.
The column names are derived from the variable declarations according to the following rules:
1. The name of the variable 'var' itself as well as any specified index references are not taken into account (but compare rule 6).
2. If 'cmp1' is a component of the first level, then all the assigned column names begin with 'cmp1'.
3. If 'cmpn' is a component of the n-th level with n > 1, then the assigned column names are continued with '_cmpn'.
4. If 'cmp' is any component array with m dimensions (m <= 4), then the assigned column names are continued with 'i1_i2_..._im', whereby i1 ... im can assume all values from 1 to the number of indexes of the particular dimension and the last dimension is run through first. Leading zeros of the indexes are not taken into account. If the array is single-dimensional, only 'i1' (without '_') is generated. If the array components are scalar, every component is assigned to exactly one column name.
5. If 'cmp' is any scalar component, then it is assigned to exactly one column name.
6. If 'var' is an array with scalar elements, then, deviating from rule 1, the assigned column names begin with 'var' and are continued according to rule 4.
Instead of the specification '!var', any structured component of 'var' can be selected, e.g., '!var.x.y'. In this case, a corresponding subset of column names is generated according to the rules 1 to 4.
The column names formed according to the rules 1 to 6 may contain up to 18 characters. Example:



