Date: Mon, 14 May 2001 08:46:52 -0500 From: Tom ONeil <tom.oneil@tacni.com> To: Free <freebsd-isp@freebsd.org> Subject: sed question - phone list Message-ID: <3AFFE1CC.E89BA8D7@tacni.com>
next in thread | raw e-mail | index | archive | help
Greetings All;
I have a script that handles our pop numbers and it requires I change
the format of a large poplist we use for input.
This is the format - CA,Anaheim,714,408,4411
and what I need is - CA,Anaheim,714-408-4411
because I don't enough perl to modify the script and I can't figure out
how use sed to do it.
awk will do the substitution, but removes the first 2 commas in the
process.
awk -F, '{print $1,$2,$3,-$4,-$5}' poplist
Thoughts? snippets of code?
Tom
--
Thomas J. ONeil tom.oneil@tacni.net
http://www.tacni.net/
"National power, local presence"
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-isp" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3AFFE1CC.E89BA8D7>
