List:General Discussion« Previous MessageNext Message »
From:Paul Nowosielski Date:December 1 2008 8:31am
Subject:regular expressions matching only numeric characters in order
View as plain text  
Dear All,

I'm trying to create a regular expression query to match phone numbers
in a database field.

My issue is this , the numbers have no set standard for input in the db.

So the number in the db could be in multiple formats.

EX:
333.333.3333
(333)333-3333
333-333-3333
3333333333

So I am wanting to find matches and ignore any non-numeric values and
need some help with the expression.

The query would be something like:

SELECT tel FROM leads WHERE do_not_call = '1' AND tel  REGEXP 'the expression'

The number I am looking for will already have all the non numerics stripped and will
be in the format of nnnnnnnnnn.

Any help would be appreciated.

Thank you,

Paul



      
Thread
regular expressions matching only numeric characters in orderPaul Nowosielski1 Dec
  • Re: regular expressions matching only numeric characters in orderPaul Nowosielski1 Dec