If the numbers are always in that format, and if there are no other '-' characters in the field, and there is only one phone number in the field, you can use the SQL POSITION function:

update filea set fielda = substr(fielda, position('-' in fielda) - 3, 12) = '555-555-5555'
where position('-' in fielda) <> 0

Another idea is grep, in QShell. This'd be more like the other ideas, to go to the PC, but you stay on the 400. There've been some posts in this group on that, or you could look up Ted Holt and grep in a google.


At 11:24 AM 3/12/2004 -0500, you wrote:
I've got a physical file (actually copy of a spool file) containing phone
#'s in format xxx-xxx-xxxx.  I need to send this to a software vendor but
for privacy reasons I need to change all the phone #'s to "fictitous"
numbers i.e. change 706-678-9565 to 945-224-4848 or such.  The phone numbers
start in a various # of places in the file (i.e. some might start in
position 33 others 55, 87 etc.) I've been racking my brain for a quick and
dirty way to this without having to manually edit the file.  Any ideas from
some of you genius' out there?

Mark Allen
IS Manager
Wilkes Telephone & Electric
11 W. Court Street
Washington, GA 30673
Phone: (706) 678-9565
Fax: (706) 678-1000

As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2022 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.