Re: How to clean up phone-numbers with regex?

From: David G Johnston <david(dot)g(dot)johnston(at)gmail(dot)com>
To: pgsql-sql(at)postgresql(dot)org
Subject: Re: How to clean up phone-numbers with regex?
Date: 2014-05-19 15:52:12
Message-ID: 1400514732379-5804493.post@n5.nabble.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Steve Crawford wrote
> On 05/19/2014 01:54 AM, Andreas wrote:
>
>>
>> Second but similar question:
>> How can I select records that have fields that contain characters not
>> included in a given alphabet?
>> E.G. find fields that contain some char not in 0-9,a-z,A-Z, +-()/?
>>
> See regexp_match on the above-referenced page.
>
> Cheers,
> Steve

Actually, section "9.7.3. POSIX Regular Expressions" - specifically table
9-11 at the beginning of that section - is the most common way to perform
the tests in a where clause. regexp_matches(...) is for when you want to
extract data.

David J.

--
View this message in context: http://postgresql.1045698.n5.nabble.com/How-to-clean-up-phone-numbers-with-regex-tp5804450p5804493.html
Sent from the PostgreSQL - sql mailing list archive at Nabble.com.

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Dariyoosh Dariyoosh 2014-05-27 12:39:59 Question about Array data type in PostgreSQL and their link with hash table concept
Previous Message Rob Sargent 2014-05-19 15:49:32 Re: How to clean up phone-numbers with regex?