Re: [SQL] Function with default value?

2006-01-29 Thread Daniel CAUNE
> -Message d'origine- > De : Tom Lane [mailto:[EMAIL PROTECTED] > Envoyé : dimanche 29 janvier 2006 10:48 > À : Daniel CAUNE > Cc : pgsql-sql@postgresql.org > Objet : Re: [SQL] Function with default value? > > Daniel CAUNE <[EMAIL PROTECTED]> wri

Re: [SQL] Function with default value?

2006-01-29 Thread Tom Lane
Daniel CAUNE <[EMAIL PROTECTED]> writes: > Is it possible to define a function with some default values? > CREATE OR REPLACE FUNCTION foo(i IN int, j IN int DEFAULT := 1) No. But you can fake many versions of this with a family of functions: CREATE OR REPLACE FUNCTION foo(i IN int, j IN int) ...

[SQL] Function with default value?

2006-01-29 Thread Daniel CAUNE
Hi,   Is it possible to define a function with some default values?   CREATE OR REPLACE FUNCTION foo(i IN int, j IN int DEFAULT := 1) …   Anyway, I didn’t find such a feature described in the PostgreSQL 8.1 documentation, but sometimes, that doesn’t mean that the feature doesn’t exis