pg.ddx.io  pgsql-php@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: timothy_maguire@hartehanks.com
To: Jon Hassen <jhassen@azstarnet.com>
Cc: arun kv <arun@library.iisc.ernet.in>
Cc: PGSQL <pgsql-php@postgresql.org>
Cc: pgsql-php-owner@postgresql.org
Subject: Re: case insensitive search
Date: Fri, 15 Mar 2002 12:40:34 -0500
Message-ID: <OF29FC6A69.1235D51D-ON85256B7D.0060FDA2@hartehanks.com> (raw)


I also use the ~* operator for situations like these

select * from table
where field ~* 'searchterm'
and ....

Tim.

Timothy P. Maguire
Web Developer II
Harte-Hanks
978 436 3325



                                                                                                                              
                      Jon Hassen                                                                                              
                      <jhassen@azstarnet.        To:       arun kv <arun@library.iisc.ernet.in>, PGSQL                        
                      com>                        <pgsql-php@postgresql.org>                                                  
                      Sent by:                   cc:                                                                          
                      pgsql-php-owner@pos        Subject:  Re: case insensitive search                                        
                      tgresql.org                                                                                             
                                                                                                                              
                                                                                                                              
                      03/15/2002 12:36 PM                                                                                     
                                                                                                                              
                                                                                                                              




Have you looked in the manual?

Try: 'where ILIKE 'searchword';

At 12:01 PM +0530 3/15/02, arun kv wrote:
>hello,
>        how to do a case insensitive search on postgresql database. i will
>enter a keyword in text field and it has to search for that keyword in
>keywords field of table and should be case insensitive.
>
>can i use egrei() function. if so how.here two attributes should be
>strings. but first attribute i will get from previous php page and second
>attribute is field name of database table. how do i do this.
>  pls help me
>      thanking you
>       Arun
>
>
>---------------------------(end of broadcast)---------------------------
>TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org




---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to majordomo@postgresql.org so that your
message can get through to the mailing list cleanly
HARTE- HANKS PRIVILEGED AND CONFIDENTIAL INFORMATION- if you are not the
addressee or authorized to receive this for the addressee, you must not
use, copy, disclose or take any action based on this message or any
information herein and should delete this message.







view thread (5+ messages)

Message-ID: <OF29FC6A69.1235D51D-ON85256B7D.0060FDA2@hartehanks.com>
Permalink:  ../OF29FC6A69.1235D51D-ON85256B7D.0060FDA2@hartehanks.com/
Also on:    postgresql.org/message-id/OF29FC6A69.1235D51D-ON85256B7D.0060FDA2@hartehanks.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-php@postgresql.org
  Cc: timothy_maguire@hartehanks.com, jhassen@azstarnet.com, arun@library.iisc.ernet.in, pgsql-php-owner@postgresql.org
  Subject: Re: case insensitive search
  In-Reply-To: <OF29FC6A69.1235D51D-ON85256B7D.0060FDA2@hartehanks.com>
  References: <OF29FC6A69.1235D51D-ON85256B7D.0060FDA2@hartehanks.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox