Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8761349
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T15:15:50+00:00 2026-06-13T15:15:50+00:00

I have phone number list on our PhoneNos table ID | PhoneNo 1 |

  • 0

I have phone number list on our PhoneNos table

ID | PhoneNo
1 | +61 2 9666 8000 

We try to search this phone no into our Content table (ie. desc field)

The challenge is actualy:

The desc field is a text and the input can be any thing such as:

ContentID | Desc    
1 | bla bla ... +61 (02) 9666 8000 ... bla bla
2 | bla bla ... +61-2-9666-8000 bla bla
3 | bla bla ... +61 2 96668000 bla bla
4 | bla bla ... +61296668000 00116129668000 bla bla

or could be anything arranging from extra spacing such as

5 | bla bla ... +61  (02) 9666   8000 ... bla bla
6 | bla bla ... +61-2 9662 0382 ... bla bla

That’s an Australia phone number BUT again it could be USA or any other countries SO it’s not tight with 1 particular country.

This phone no have no pattern what so ever before and after this phone no. So it could be anything.

Is there anyway to handle this sort of thing easily? I can probably construct each condition above BUT I’m just wondering if there is a better solution.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T15:15:51+00:00Added an answer on June 13, 2026 at 3:15 pm

    My (highly uneducated) thought would be to use a regular expression replace (see here). Essentially strip everything in the content except for numbers and plus signs (feeling clunky yet? 🙂 ), and then compare to your control string with the same processing (\\+\d+, basically). That makes the rather broad assumption that there will be no false positives created by another random string of numbers/characters matching your number (I imagine somewhat unlikely from a probability perspective, but always a possibility).

    I was tinkering around with what I’m sure is highly inefficient, inelegant and likely incorrect solution, and realized that it won’t handle the case with a leading 0 inside parentheses (since this doesn’t seem to be present in other patterns). You can find it here if you’re curious, but I think the regex solution may be the most efficient way to handle.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a list of calling codes for all countries(the phone number prefixes), I
If I have an international phone number such as this: 0541754301 how can I
I have a mySQL table with list of people and phone numbers. There are
I'm building a small internal phone number extension list. In the database I have
I'd like to get a list of all ABContacts that have a phone number
I have a list of phone numbers that have been dialed (nums_dialed). I also
Okay, basically, I have a large list of phone numbers in a text file
I have phone number. Is there any way to check whether the phone number
I have a phone number field that can have lots of different characters such
I have a phone number I want to match against a regular expression. The

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.