hello,
I have been working on extracting a report in Unix and stuck on the following.
The file contents are as follows and I would like to do the following
================================================================================
Autootaal 8711768000011 (AUTOTAAL)
--------------------------------------------------------------------------------
Directory Entry Type........... N
Last Call :....................
Date/Time................... 07/03/09 12:36:29
Status...................... Successful
Attempts.................... 3
Max. call retries.............. 999 at 10 minute intervals
================================================================================
ETS ARENDAL (ETSTESTS)
--------------------------------------------------------------------------------
Directory Entry Type........... N
Last Call :....................
Date/Time................... 07/04/27 16:21:28
Status...................... Successful
Attempts.................... 0
Max. call retries.............. 7 at 10 minute intervals
================================================================================
Audi Files to ETS System AUO0932109936351TAE (AU2ETS00)
--------------------------------------------------------------------------------
Directory Entry Type........... N
Last Call :....................
Date/Time................... 06/02/21 16:01:06
Status...................... Ftp Code = 000 X.25 Cause = 013 X.25 Diag =
Attempts.................... 7
Max. call retries.............. 7 at 10 minute intervals
================================================================================
The records are separated by " =====" Now I have to parse these records and if the Attempts is more than 0 then only those have to be pulled.
eg above - > ETS has the Attenot as zero, so I have to skip those.
I am new to sed & awk, any help is greatly appreciated.
Thank you
Rakesh