Using User-Defined SQL Functions
User-Defined SQL Functions let you define and store commonly-used SQL expressions as a function. User-Defined SQL Functions are useful for executing complex queries and combining Vertica built-in functions. You simply call the function name you assigned in your query.
A User-Defined SQL Function can be used anywhere in a query where an ordinary SQL expression can be used, except in the table partition clause or the projection segmentation clause.
For syntax and parameters for the commands and system table discussed in this section, see the following topics in the SQL Reference Manual: