Re: Regular Expression Matching problem... - Mailing list pgsql-sql

From Mario Splivalo
Subject Re: Regular Expression Matching problem...
Date
Msg-id 1136769769.19539.2.camel@localhost.localdomain
Whole thread Raw
In response to Re: Regular Expression Matching problem...  (Michael Fuhr <mike@fuhr.org>)
List pgsql-sql
On Wed, 2006-01-04 at 10:00 -0700, Michael Fuhr wrote:

> What Andreas is saying is that the patterns in the table have too
> many backslashes.  The original query was
> 
> test=> select '+385911234567' ~ '^\\+38591\\d{7}$';
>  ?column? 
> ----------
>  t
> (1 row)
> 
> but if you select just the pattern you get
> 
> test=> select '^\\+38591\\d{7}$';
>     ?column?    
> ----------------
>  ^\+38591\d{7}$
> (1 row)

I was a bit silly here. Dunno why I tought I need to escape the
backslashes when entering regexp as data in table. Thank you for
pointing that out.
Mike



pgsql-sql by date:

Previous
From: Andrew Sullivan
Date:
Subject: Re: INSERT waiting under heavy load
Next
From: David Ford
Date:
Subject: system view corrupted, i get "unexpected right parenthesis" for many system tables.