Re: CONCAT function - Mailing list pgsql-general

From Csaba Nagy
Subject Re: CONCAT function
Date
Msg-id 1063718154.29402.28.camel@coppola.ecircle.de
Whole thread Raw
In response to Re: CONCAT function  ("Marek Lewczuk" <newsy@lewczuk.com>)
List pgsql-general
Search the recent archives for "DECODE" and "NVL" (those are Oracle
functions, but people had he same problems with them as you with
CONCAT).
The basic idea is that in postgres you can overload functions, so you
can create more versions of the function with different parameter
counts/types. Just make sure you implement all the variations you use in
your code.

Cheers,
Csaba.


On Tue, 2003-09-16 at 15:50, Marek Lewczuk wrote:
> >
> > text concat(text,text)
> >
> >  return text1 || text2
> >
>
> If it would be so simple I would not write to this group. You see,
> CONCAT function doesn't have any arguments limitations, so there could
> be one, two or more arguments. And this is my problem, how to write
> function without given arguments number.
>
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org



pgsql-general by date:

Previous
From: "scott.marlowe"
Date:
Subject: Re: Odd behaviour -- Index scan vs. seq. scan
Next
From: "scott.marlowe"
Date:
Subject: Re: CONCAT function