• Lifeport
  • NEWBIE
  • 0 Points
  • Member since 2012

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 1
    Replies

Hi,

 

I am trying to write a validation formula that will allow two format types for UK phone numbers, these are;

01234 567890 and 0123 456 7890.

 

Whilst I can write a validation rule for one format type; 

 

NOT(REGEX(Phone, "\\d{4}( \\d{3})( \\d{4})")).

 

I cannot seem to write a rule that will allow for two. I had tried;

 

OR(NOT(REGEX(Phone, "\\d{4}( \\d{3})( \\d{4})")), NOT(REGEX(Phone, "\\d{5}( \\d{6})")))

 

But this does not work. Any advice to what I am hoping is a simple answer would be grateful.