Welcome guest. Before posting on our computer help forum, you must register. Click here it's easy and free.

Author Topic: Need unix shell script to extract some records  (Read 3815 times)

0 Members and 1 Guest are viewing this topic.

kanthmca3

    Topic Starter


    Newbie

    • Experience: Beginner
    • OS: Unknown
    Need unix shell script to extract some records
    « on: December 06, 2010, 03:58:18 AM »
    i need to extract the fields which are Highlighted in the attached document.
    and moreover i want to extract in the following way.
    starting from the first column i have to go n(say n=13) lines down and extract "Records" field value


    Thanks in advance


    Regards
    kanth




    [recovering disk space - old attachment deleted by admin]

    kanthmca3

      Topic Starter


      Newbie

      • Experience: Beginner
      • OS: Unknown
      Re: Need unix shell script to extract some records
      « Reply #1 on: December 06, 2010, 04:46:16 AM »
      The file looks like this :
      Oct 03 10:59:53   Phase 2 ended (4 seconds)
                              CPU Time  Status Skew Vertex
                                 0.270 [  : 1]   0% Logs_1.Gather
                                 0.240 [  : 1]   0% Logs_1.Gather_1
                                 0.330 [  : 1]   0% Logs_1.Gather_3
                                 0.200 [  : 1]   0% Logs_1.Trash
                                 0.540 [  : 1]   0% Partition_by_Key
                                 8.470 [  :12]   0% Update_Table_Card_Dtl_2
      --------------------------------------------------------------------------------
             Data Bytes         Records      Status      Skew Flow        Vertex                                                Port
                  5,040              60 [    :    :   1]   0% Flow_10     Partition_by_Key                                      in
                  5,040              60 [    :    :  12]  58% Flow_18     Partition_by_Key                                      out
                  5,040              60 [    :    :  12]  58% Flow_18     Update_Table_Card_Dtl_2                               in
                      0               0 [    :    :  12]   0% Flow_19     Update_Table_Card_Dtl_2                               reject
                      0               0 [    :    :  12]   0% Flow_19     Logs_1.Gather                                         in
                      0               0 [    :    :  12]   0% Flow_20     Update_Table_Card_Dtl_2                               error
                      0               0 [    :    :  12]   0% Flow_20     Logs_1.Gather_1                                       in
                 43,248             300 [    :    :  12]   0% Flow_21     Update_Table_Card_Dtl_2                               log
                 43,248             300 [    :    :  12]   0% Flow_21     Logs_1.Gather_3                                       in
                 43,248             300 [    :    :   1]   0% Logs_1.Flow_1 Logs_1.Gather_3                                       out
                 43,248             300 [    :    :   1]   0% Logs_1.Flow_1 Logs_1.Trash                                          in
                      0               0 [    :    :   1]   0% Logs_1.Flow_2 Logs_1.Gather                                         out
                      0               0 [    :    :   1]   0% Logs_1.Flow_3 Logs_1.Gather_1                                       out
      --------------------------------------------------------------------------------
      2010-10-03 10:59:56 #--- Ended

      please open the attachment for clear description.