Extract only those records from a PS file which are having word 'TEXT' in the records using COBOL? The word TEXT is not present in a particular position in all the records.
Answer Posted / divyakiruthiga
Step 1: Read the first record from the PS file into a ws-variable WK-ROW.
Step 2 :INSPECT WK-ROW TALLYING WK-TXT-COUNT FOR ALL 'TEXT'.
Step 3: If the WK-TXT-COUNT is greater than 0, then write the record to the output file.
Step 4: Initialize the WK-TXT-COUNT
Step 5: Continue the above process till end of file.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Differentiate between structured cobol programming and object-oriented cobol programming.
What the difference is between continue and next sentence?
Explain the configuration section of a cobol program with examples of syntax.
I have program P1 which calls file F1 which has 100 records and following structure 001 .................. 002 .................. 003 .................. 098 .................... 099 ................... 100 .................... Now I want to read these files and write these records in file F2 in following manner. 001 ...... 051 ..... 002 ...... 052 ..... 003 ...... 053 ..... .......... ....... .......... ....... .......... ....... 048 ........ 098 ...... 049 .......... 099 ....... 050 .... 100 ......
i made it to stage 3 of an interview process wednessday they will quiz my knowledge again face to face for an analyst role recruiter said it will be based on Business requirements system is cobol and good ideas what they might ask etc
What is link edit in cobol?
How do we get current date from system with century in COBOL?
How do define dynamic array in cobol. how do you define single dimensional array and multidimensional array in your cobol?
Name some of the examples of COBOl 11?
Whats the difference between search & search ALL?
What is length is cobol?
State the various causes of s0c1, s0c5 and s0c7.
Difference between array and sub-script ?
) what is the difference between AID and HANDLE AID?
In which area will you utilize 88 level items in cobol?