pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Brett W. McCoy <bmccoy@chapelperilous.net>
To: Sebastian --[ www.flashhilfe.de ]-- <hallogammler@aol.com>
Cc: pgsql-sql@postgresql.org
Subject: Re: Search
Date: Tue, 6 Feb 2001 09:09:55 -0500 (EST)
Message-ID: <Pine.LNX.4.30.0102060905260.5205-100000@chapelperilous.net> (raw)
In-Reply-To: <95n58g$5fa$1@news.tht.net>

On Mon, 5 Feb 2001, Sebastian --[ www.flashhilfe.de ]-- wrote:

> I have make a search machine whit:
>
> LIKE '%$suchbegriffe[$i]%'
>
> but when I search Test - the search machine shows only entries
> whit Test. But not test or tESt.

LIKE is case-sensitive.  You should convert your column to uppercase:

WHERE UPPER(field) LIKE ...

or use case-insensitive regular expression:

WHERE field ~* '<regexp>'

-- Brett
                                     http://www.chapelperilous.net/~bmccoy/
---------------------------------------------------------------------------
The Angels want to wear my red shoes.
		-- E. Costello






view thread (5+ messages)  latest in thread

Message-ID: <Pine.LNX.4.30.0102060905260.5205-100000@chapelperilous.net>
Permalink:  ../Pine.LNX.4.30.0102060905260.5205-100000@chapelperilous.net/
Also on:    postgresql.org/message-id/Pine.LNX.4.30.0102060905260.5205-100000@chapelperilous.net

 · 

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-sql@postgresql.org
  Cc: bmccoy@chapelperilous.net, hallogammler@aol.com
  Subject: Re: Search
  In-Reply-To: <Pine.LNX.4.30.0102060905260.5205-100000@chapelperilous.net>
  References: <95n58g$5fa$1@news.tht.net> <Pine.LNX.4.30.0102060905260.5205-100000@chapelperilous.net>

* 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