Page 1 of 1

To read and eliminate some records

PostPosted: Tue Dec 25, 2012 3:01 am
by Viswanathchandru
Dear all,

I would need help/suggestion to read and eliminate some records that came as a result of some operations. I have a record as shown below. I need to eliminate the one's which are without '$$' symbol mentioned below
PSDGPDG RECORD FORMATTED SUCCESSFULLY
       $$FORMATTED RESULTS NEEDS CROSS VERIFICATION

PSDGPDH RECORD FORMATTED SUCCESSFULLY
PSDGPDJ RECORD FORMATTED SUCCESSFULLY
       $$FORMATTED RESULTS NEEDS CROSS VERIFICATION
. Here I just listed a piece of the record I have. I just want to remove "
PSDGPDH RECORD FORMATTED SUCCESSFULLY" which doesn't have any other information next to it. I mean there are no "$$ FORMATTED RESULTS NEEDS CROSS VERIFICATION". In other words I need to capture the PSDGPD* records which has an Information as "$$ FORMATTED RESULTS NEEDS CROSS VERIFICATION". Hope I'm clear. Please let me know if I need to explain more. Any suggestions or help would be great! Apologize if I'm wrong.


Regards,
Viswa

Re: Help needed.

PostPosted: Tue Dec 25, 2012 3:11 am
by Akatsukami
Clear as mud. I suppose that with a PSDGPD header a new "logical" record begins that extends over one or more lines until the next header?

Re: Help needed.

PostPosted: Tue Dec 25, 2012 3:21 am
by Viswanathchandru
Hi Akatsukami,

Thanks for your time!

Akatsukami wrote: Clear as mud.
I expected.

Ok, let me explain bit more. I've got a flat file which has the records like mentioned above. I'm not sure how those were generated. But my aim is to filter out the ones which needs "CROSS VERIFICATION"

Here, PSDGPDG is a module/report name which was formatted using some tool which I'm not aware. If I see the next line saying "$$ FORMATTED RESULTS NEEDS CROSS VERIFICATION" I need to filter out the name PSDGPDG.
In other words, If I don't find "$$ FORMATTED RESULTS NEEDS CROSS VERIFICATION" as in the case of PSDGPDH I just want to delete that record/line. Hope I'm clear.


Regards,
Viswa

Re: Help needed.

PostPosted: Tue Dec 25, 2012 3:53 am
by enrico-sorichetti
after two years of hanging around still using stupid titles ... :mrgreen:
not even REXX related

You have lots more to explain
if You do not learn to post properly Your requirements Your need for help will remain unfulfilled

why not use the GROUP/INCLUDE/OMIT facilities of Your <SORT> product

it would be wise for You, to make the most out of the questions You ask
to read and meditate on ...
How To Ask Questions The Smart Way here
http://catb.org/~esr/faqs/smart-questions.html