What does VARIADIC declarations mean in PostgreSQL?

When you are not sure about the number of parameters then we use Variadic.

You can refer VARIADIC FUNCTIONS IN POSTGRESQL for details.

See the wiki about Variadic functions:

In computer programming, a variadic function is a function of indefinite arity, i.e., one which accepts a variable number of arguments. Support for variadic functions differs widely among programming languages.


Variadic functions are those with an undefined number of arguments, they are present in many programming and query languages.

In the case of PostgreSQL, you can find an example at http://www.postgresql.org/docs/9.1/static/xfunc-sql.html (35.4.5. SQL Functions with Variable Numbers of Arguments):

Effectively, all the actual arguments at or beyond the VARIADIC position are gathered up into a one-dimensional array, as if you had written

Tags:

Sql

Postgresql