1 CREATE FUNCTION function-name (
2? 
2+ ,
2 parameter-declaration
3 ) RETURNS TABLE (
4+ ,
4 column-name data-type2
5 )
6 LANGUAGE SQL option-list
7? SET OPTION-statement
8 SQL-routine-body

parameter-declaration:

1 parameter-name data-type1

data-type1, data-type2:

1 built-in-type
1 distinct-type-name