Re: Overloading || ( text,text ) operator

From: Richard Huxton <dev(at)archonet(dot)com>
To: Suresh Tri <trisuresh(at)yahoo(dot)co(dot)in>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Overloading || ( text,text ) operator
Date: 2004-09-06 14:16:48
Message-ID: 413C7150.3080801@archonet.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Suresh Tri wrote:
>
> But when I try to drop the existing || operator, I get the following
> error
> ERROR: cannot drop operator ||(text,text) because it is required by
> the database system
>
> Also I cannot modify the application which runs over the database.
> Hence I cannot overload || (varchar,varchar) and use it.
>
> Is there any way of overloading the || operator , such that it behaves
> like Oracle? ( I know that Oracle behaviour is wrong , but my aim is
> to move an existing application which runs on Oracle to Postgres :-(
> )

Your best bet might be to define your own type "oraclevarchar" with stub
implementations of most functions/operators except those you want to
oracle-ise.

--
Richard Huxton
Archonet Ltd

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Randy Yates 2004-09-06 14:38:11 Re: One Database per Data File?
Previous Message Martin Münstermann 2004-09-06 13:42:07 Re: One Database per Data File?