Re: RE in WHERE

From: Jeff Eckermann <jeff_eckermann(at)yahoo(dot)com>
To: Patrick Nelson <pnelson(at)neatech(dot)com>, "PostgreSQL List (E-mail)" <pgsql-general(at)postgresql(dot)org>
Subject: Re: RE in WHERE
Date: 2002-10-10 19:30:58
Message-ID: 20021010193058.15843.qmail@web20808.mail.yahoo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


--- Patrick Nelson <pnelson(at)neatech(dot)com> wrote:
> SELECT * FROM secure WHERE ~ '^12\.';
>
> displays
>
> host
> -----------------
> 12.28.18.10
> 12.41.17.174
> 128.121.247.126
> ...
>
> Escaping the dot should only show the 12. entries
> right? What is the proper
> RE for this?
>
Your statement goes through two rounds of parsing,
with escape characters being stripped off each time,
so your literal '.' is being interpreted as a
metacharacter. Try doubling your backslash escape.

__________________________________________________
Do you Yahoo!?
Faith Hill - Exclusive Performances, Videos & More
http://faith.yahoo.com

In response to

  • RE in WHERE at 2002-10-10 19:13:57 from Patrick Nelson

Browse pgsql-general by date

  From Date Subject
Next Message Joe Maldonado 2002-10-10 19:31:16 Re: RE in WHERE
Previous Message Jean-Luc Lachance 2002-10-10 19:27:31 Re: RE in WHERE