how can we fetch 3 records in cobol pgm any coding pls ?

Answer Posted / santhosh

Read the file and validate the things, once the all the
things are done for the record keep the count of it in an
working storage variable. Everytime when u try to read the
next record check for the count of WS variable, when it
reaches the count of 3 then terminate ur program.

Is This Answer Correct ?    6 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Write a cobol program making use of the redefine clause.

717


what is s000 u4087 error? please give the all error codes in cobol,jcl.

17009


What is a report item?

729


What are the different rules to perform a Search?

610


In COBOL, what is the different between index and subscript?

749






Have you used the sort in your project?for this type of questions any working on real time project give the eg. with real time scenario.

2045


What is the LINKAGE SECTION used in COBOL?

881


For rewrite, why is it mandatory that file needs to be opened?

613


What is redefines clause in COBOL?

837


How do we get current date from system with century in COBOL?

790


Write a program to enter and display the names of students in a class using the occurs clause.

640


write a cobol logic. i have file that has 10 records .1 record go to first output file and second record goes to 2 output and etc

689


how can i see junk values in dclgen or in hostvariable of comp ?

2532


What is the utilization of copybook in cobol? Could we utilize a similar copybook?

702


What is the difference between external and global variables in COBOL?

804