Ernie Tucker wrote:
>
> I have a file with the following data in it. What I am trying to do is just
> grab the mac id. Is there a good way to do this in perl. I tried to grep on
> just 00 but that gave me more info than what I need. Thanks for any help.
>
> 0008.0e39.ad80
> Account: 10391-xxxxx
> Name: glusick, dave
> Status: scheduled
> Install Date: 2002-06-03
> Address: 850 xxxxxx,
> sun prarie, wi 53590
> Phone: (608) xxx-xxxx
> Headend: athome
> Node:
> ==================================================
> 0004.bdca.04a0
> Account: 10391-xxxxx
> Name: NUNN, ROBBIE
> Status: scheduled
> Install Date: 2002-06-03
> Address: 1106 N xxxxx,
> SUN PRAIRIE, WI 53590
> Phone: (608) xxx-xxxx
> Headend: athome
> Node:
perl -lne'/^[[:xdigit:]]{4}(?:\.[[:xdigit:]]{4}){2}$/&&print' yourfile
John
--
use Perl;
program
fulfillment
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]