Extracting fields from a data file
From: Mohammed Chafik (chafik_at_mail.com)
Date: 06/29/04
- Next message: Wiggins D Anconia: "Re: Extracting fields from a data file"
- Previous message: Wiggins D Anconia: "Re: mail"
- Next in thread: Wiggins D Anconia: "Re: Extracting fields from a data file"
- Maybe reply: Wiggins D Anconia: "Re: Extracting fields from a data file"
- Maybe reply: Bob Showalter: "RE: Extracting fields from a data file"
- Reply: Philipp Traeder: "Re: Extracting fields from a data file"
- Maybe reply: Mohammed Chafik: "Re: Extracting fields from a data file"
- Reply: Charles K. Clarkson: "RE: Extracting fields from a data file"
- Maybe reply: Wiggins D Anconia: "Re: Extracting fields from a data file"
- Maybe reply: Wiggins D Anconia: "Re: Extracting fields from a data file"
- Maybe reply: Mohammed Chafik: "Re: Extracting fields from a data file"
- Maybe reply: Mohammed Chafik: "RE: Extracting fields from a data file"
- Reply: John W. Krahn: "Re: Extracting fields from a data file"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
To: beginners@perl.org Date: Tue, 29 Jun 2004 10:04:08 -0500
Hi all,
I have input file like this:
------------------------------------------------------------------------
header, 06-12-2004, path, /usr/bin/sh,attribute,100555,root,other,315,565690, subject,bscs,sgrp,9936,6785,0 0,return,success,0 (line1)
header, 06-12-2004, path, /usr/bin/sh,attribute,100555,dba,5, subject,bscs,sgrp,9936,6785,0 ,return,success,0 (line2)
header, 06-12-2004, path, /usr/bin/sh,attribute,100555,tom,other,315,56,11,54,77,10,88, subject,bscs,sgrp,9936,6785,0 0,return,success,0 (line3)
-----------------------------------------------------------------------
I need to generate an output file like this (deleting fields between attribute and subject, please
note that number of those fields is variable):
-----------------------------------------------------------------------------------
header, 06-12-2004, path, /usr/bin/sh, subject,bscs,sgrp,9936,6785,0 0,return,success,0 (line1)
header, 06-12-2004, path, /usr/bin/sh, subject,bscs,sgrp,9936,6785,0 0,return,success,0 (line 2)
header, 06-12-2004, path, /usr/bin/sh, subject,bscs,sgrp,9936,6785,0 0,return,success,0 (line 3)
-----------------------------------------------------------------------------------
Thanks a lot ,
CHAFIK
-- ___________________________________________________________ Sign-up for Ads Free at Mail.com http://promo.mail.com/adsfreejump.htm
- Next message: Wiggins D Anconia: "Re: Extracting fields from a data file"
- Previous message: Wiggins D Anconia: "Re: mail"
- Next in thread: Wiggins D Anconia: "Re: Extracting fields from a data file"
- Maybe reply: Wiggins D Anconia: "Re: Extracting fields from a data file"
- Maybe reply: Bob Showalter: "RE: Extracting fields from a data file"
- Reply: Philipp Traeder: "Re: Extracting fields from a data file"
- Maybe reply: Mohammed Chafik: "Re: Extracting fields from a data file"
- Reply: Charles K. Clarkson: "RE: Extracting fields from a data file"
- Maybe reply: Wiggins D Anconia: "Re: Extracting fields from a data file"
- Maybe reply: Wiggins D Anconia: "Re: Extracting fields from a data file"
- Maybe reply: Mohammed Chafik: "Re: Extracting fields from a data file"
- Maybe reply: Mohammed Chafik: "RE: Extracting fields from a data file"
- Reply: John W. Krahn: "Re: Extracting fields from a data file"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|