Pages: [1]
Author Topic: Telephone number and address verification  (Read 935 times)
Posts: 2

« on: February 11, 2011, 05:55:30 PM »

Hi all!

I'm wondering if anyone has used this program to verify telephone numbers or addresses that have been submitted - just to make sure that what we're putting in that we think is a telephone number/ address actually is.

I've been thinking about the process to use, and I've come up with 2 options for the telephone number verification, but I'm not sure how to implement them. First, I thought that I'd be able to keep a database of all known numbers and cross-check any numbers that come into the system to see if they're present in this list. I also thought that I'd be able to run the specific number through a set of rules that all telephone numbers in the United States follow (10 digits, area code can't begin with a 0 or 1, etc.). But I'm not sure how to cross-check a number against a database or send a number through a set of validation rules.

I'd really appreciate any insight to this! Thanks so much!
Hero Member
Posts: 852

« Reply #1 on: February 11, 2011, 07:06:15 PM »

Hi there,

In RM you can do this by using a filter that applies a parsing rule, in the form of what is called a "regular expression". Regular expressions are strings that act as templates. Libraries of strings for parsing telephone numbers already exist, and tools for making your own are available ( I use RegexBuddy ); doing Regexes without such assistance can be a little brisk  Grin Anyways, here's an example to show how easy this is, once you've got your Regex sorted out...

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<process version="5.1.001">
  <operator activated="true" class="process" compatibility="5.1.001" expanded="true" name="Process">
    <process expanded="true" height="361" width="807">
      <operator activated="true" class="retrieve" compatibility="5.1.001" expanded="true" height="60" name="Retrieve" width="90" x="56" y="116">
        <parameter key="repository_entry" value="//Samples/data/Labor-Negotiations"/>
      <operator activated="true" class="filter_examples" compatibility="5.1.001" expanded="true" height="76" name="Filter Examples" width="90" x="313" y="210">
        <parameter key="condition_class" value="attribute_value_filter"/>
        <parameter key="parameter_string" value="vacation=.*-.*"/>
      <connect from_op="Retrieve" from_port="output" to_op="Filter Examples" to_port="example set input"/>
      <connect from_op="Filter Examples" from_port="example set output" to_port="result 1"/>
      <portSpacing port="source_input 1" spacing="0"/>
      <portSpacing port="sink_result 1" spacing="0"/>
      <portSpacing port="sink_result 2" spacing="0"/>

Have fun!


Where is the wisdom we have lost in knowledge?
Where is the knowledge we have lost in information?

T.S.Eliot ~ Choruses from the Rock 1934
Pages: [1]
Jump to: