Taking a closer look at Function Tables, there are some properties that should be noted.
- There are no anchor columns and there is no anchor table replacement when the anchor table is a Function Table.
- A Table function may only be used once in a FROM clause (i.e., as a Function Table) and not in a FROM clause that includes a JOIN, whereas Table Operators and Aster SQL-Map Reduce functions can appear more than once in a FROM clause or in a FROM clause with a JOIN.
- If a referenced analysis representing a subquery or a With Query is used in conjunction with a Function Table, you cannot select columns from the Function Table until the current analysis is executed once and the subquery or With Query is marked as “Generate SQL Only”. It may be necessary to include a New Variable or a literal value temporarily in order to get the current analysis to execute.
- Every output column of a Table function is presumably contributed to by every input parameter column, and this is recorded in the Advertised Output, unless the parameter column comes from a referenced analysis.
- Advertise Output contributing columns will indicate a Table Operator, just as any other table with columns, with the exception that the database will be blank and the table name is the name of the Function Table. Note that the input table or query of a Table Operator will not be searched for contributing columns. In some sense, every column in the input table of a Table Operator may be seen to contribute to every column in the output table of the operator, but no attempt is made to record this in the Advertised Output. This is also true of SQL-Map Reduce Functions in the Aster environment.
- If it is necessary to include a Function Table column in a Temporal Qualifier, a Correlation Alias should be assigned. Otherwise, the column will be qualified with the Function Table name, leading to an error.