Re: Case Insensitive comparison

Lists: pgsql-admin
From: "George A(dot)J" <jinujosein(at)yahoo(dot)com>
To: pgsql-admin(at)postgresql(dot)org
Subject: Case Insensitive comparison
Date: 2003-09-25 03:39:05
Message-ID: 20030925033905.35938.qmail@web14915.mail.yahoo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-admin

hai

i am using postgresql 7.3.x. I am converting a database in MS SQL server to PostgreSQL.

The main problems i am facing is that in sql server the text comparisons are case insensitive. how can i compare text case insensitive in postgresql without using an upper() or lower() function in both sides (=). Is there any option to set in postgresql?
Is there any problem in overriding the = operator that compare text. ie droping the current operator = and creating a new = operator(text,text). Does the existing = operator is using internally by postgres for some porpose. please help

Another problem is in creating function...
How can i create a function that accept and return any type. the type "any" is not allowing as parameter or return type. Is it possible? i want to create a function similar to NULLIF().

jinujose

---------------------------------
Do you Yahoo!?
The New Yahoo! Shopping - with improved product search


From: "Donald Fraser" <demolish(at)cwgsy(dot)net>
To: "[ADMIN]" <pgsql-admin(at)postgresql(dot)org>
Subject: Re: Case Insensitive comparison
Date: 2003-09-25 17:24:42
Message-ID: 007f01c38389$f9d463b0$1664a8c0@DEMOLITION
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-admin


----- Original Message -----
From: George A.J
To: pgsql-admin(at)postgresql(dot)org
Sent: Thursday, September 25, 2003 4:39 AM
Subject: [ADMIN] Case Insensitive comparison

>hai
>
>i am using postgresql 7.3.x. I am converting a database in MS SQL server to
PostgreSQL.
>
>The main problems i am facing is that in sql server the text comparisons are
case insensitive. how can i compare text case insensitive in postgresql
>without using an upper() or lower() function in both sides (=). Is there any
option to set in postgresql?
>Is there any problem in overriding the = operator that compare text. ie
droping the current operator = and creating a new = operator(text,text). Does
>the existing = operator is using internally by postgres for some porpose.
please help

I have created a text data type which is case-insensitive. Everything is
identical to type text in all other respects. If you would like I can email you
the library files to make and install it.

Regards
Donald Fraser


From: "scott(dot)marlowe" <scott(dot)marlowe(at)ihs(dot)com>
To: Donald Fraser <demolish(at)cwgsy(dot)net>
Cc: "[ADMIN]" <pgsql-admin(at)postgresql(dot)org>
Subject: Re: Case Insensitive comparison
Date: 2003-09-25 17:34:37
Message-ID: Pine.LNX.4.33.0309251134150.18705-100000@css120.ihs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-admin

Any chance of those libs being put somewhere public (gborg.postgresql.org
or something?)

On Thu, 25 Sep 2003, Donald Fraser wrote:

>
> ----- Original Message -----
> From: George A.J
> To: pgsql-admin(at)postgresql(dot)org
> Sent: Thursday, September 25, 2003 4:39 AM
> Subject: [ADMIN] Case Insensitive comparison
>
>
> >hai
> >
> >i am using postgresql 7.3.x. I am converting a database in MS SQL server to
> PostgreSQL.
> >
> >The main problems i am facing is that in sql server the text comparisons are
> case insensitive. how can i compare text case insensitive in postgresql
> >without using an upper() or lower() function in both sides (=). Is there any
> option to set in postgresql?
> >Is there any problem in overriding the = operator that compare text. ie
> droping the current operator = and creating a new = operator(text,text). Does
> >the existing = operator is using internally by postgres for some porpose.
> please help
>
> I have created a text data type which is case-insensitive. Everything is
> identical to type text in all other respects. If you would like I can email you
> the library files to make and install it.
>
> Regards
> Donald Fraser
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo(at)postgresql(dot)org
>


From: "Donald Fraser" <demolish(at)cwgsy(dot)net>
To: "[ADMIN]" <pgsql-admin(at)postgresql(dot)org>
Subject: Re: Case Insensitive comparison
Date: 2003-09-25 17:57:18
Message-ID: 00a901c3838e$76ae8790$1664a8c0@DEMOLITION
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-admin

Ok I will have a look at how to put it on gborg.

Regards
Donald Fraser

----- Original Message -----
From: "scott.marlowe" <scott(dot)marlowe(at)ihs(dot)com>
To: "Donald Fraser" <demolish(at)cwgsy(dot)net>
Cc: "[ADMIN]" <pgsql-admin(at)postgresql(dot)org>
Sent: Thursday, September 25, 2003 6:34 PM
Subject: Re: [ADMIN] Case Insensitive comparison

> Any chance of those libs being put somewhere public (gborg.postgresql.org
> or something?)
>
> On Thu, 25 Sep 2003, Donald Fraser wrote:
>
> >
> > ----- Original Message -----
> > From: George A.J
> > To: pgsql-admin(at)postgresql(dot)org
> > Sent: Thursday, September 25, 2003 4:39 AM
> > Subject: [ADMIN] Case Insensitive comparison
> >
> >
> > >hai
> > >
> > >i am using postgresql 7.3.x. I am converting a database in MS SQL server
to
> > PostgreSQL.
> > >
> > >The main problems i am facing is that in sql server the text comparisons
are
> > case insensitive. how can i compare text case insensitive in postgresql
> > >without using an upper() or lower() function in both sides (=). Is there
any
> > option to set in postgresql?
> > >Is there any problem in overriding the = operator that compare text. ie
> > droping the current operator = and creating a new = operator(text,text).
Does
> > >the existing = operator is using internally by postgres for some porpose.
> > please help
> >
> > I have created a text data type which is case-insensitive. Everything is
> > identical to type text in all other respects. If you would like I can email
you
> > the library files to make and install it.
> >
> > Regards
> > Donald Fraser
> >
> >
> > ---------------------------(end of broadcast)---------------------------
> > TIP 1: subscribe and unsubscribe commands go to majordomo(at)postgresql(dot)org
> >
>
>


From: "Donald Fraser" <demolish(at)cwgsy(dot)net>
To: "[ADMIN]" <pgsql-admin(at)postgresql(dot)org>
Subject: Re: Case Insensitive comparison
Date: 2003-09-25 18:33:30
Message-ID: 00ba01c38393$84d1d0c0$1664a8c0@DEMOLITION
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-admin

Ok I have started the process... I now have to wait for GBorg to get back to me
on whether they want it on the site our not.

Regards
Donald Fraser

----- Original Message -----
From: "Jamie Lawrence" <jal(at)jal(dot)org>
To: "Donald Fraser" <demolish(at)cwgsy(dot)net>
Sent: Thursday, September 25, 2003 7:04 PM
Subject: Re: [ADMIN] Case Insensitive comparison

> On Thu, 25 Sep 2003, Donald Fraser wrote:
>
> > Ok I will have a look at how to put it on gborg.
>
> When you do, can you point the list at it, or email me what you've done?
> I'd love to have this availale - I've had to write some creepy, slow
> code to simulate it. I haven't been able to think of a way to write
> something that would do this without writing something in C, which I
> haven't been willing to do yet.
>
> Thank you!
>
> -j
>
> > Regards
> > Donald Fraser
> [...]
> > > Any chance of those libs being put somewhere public (gborg.postgresql.org
> > > or something?)
> > >
> > > On Thu, 25 Sep 2003, Donald Fraser wrote:
> [...]
> > > > I have created a text data type which is case-insensitive. Everything
is
> > > > identical to type text in all other respects. If you would like I can
email
> > you
> > > > the library files to make and install it.