Package org.apache.calcite.sql.fun
Annotation Type LibraryOperator
An annotation that is read by
SqlLibraryOperatorTableFactory
to
add functions and operators to a library.
Typically, such collections are associated with a particular dialect or
database. For example, SqlLibrary.ORACLE
is a collection of functions
that are in the Oracle database but not the SQL standard.
In SqlLibraryOperatorTableFactory
this annotation is applied to
function definitions to include them in a particular library. It allows
an operator to belong to more than one library.
-
Required Element Summary
Modifier and TypeRequired ElementDescriptionThe set of libraries that this function or operator belongs to. -
Optional Element Summary
Modifier and TypeOptional ElementDescriptionThe set of libraries that this function should be excluded from.
-
Element Details
-
libraries
SqlLibrary[] librariesThe set of libraries that this function or operator belongs to. Must not be null or empty. -
exceptLibraries
SqlLibrary[] exceptLibrariesThe set of libraries that this function should be excluded from.Only needed when a library inherits functions from another library. For example,
SqlLibrary.REDSHIFT
inherits fromSqlLibrary.POSTGRESQL
, and therefore contains all of PostgreSQL's operators by default. TheSTARTS_WITH
function is in BigQuery and PostgreSQL but not in Redshift and therefore has the annotation@LibraryOperator(libraries = {BIG_QUERY, POSTGRESQL}, exceptLibraries = {REDSHIFT})
- Default:
{}
-