in a indexed file what is procedure for read the records
from 12 to 18. please give the code example

Answer Posted / santhosh vayathuri

use fallowing code

file-control
organization is indexed.
access mode is dynamic
record key is eno


procedure division

move 12 to eno


perform readpara until fnd = yes

stop run.

readpara.
read file1
if eno = 18
move 'yes' to fnd
end-if.

Is This Answer Correct ?    2 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to change size of Initial number of records to *NOMAX for ALL PF files from perticular library, how can I do that

2728


How to traceback if I am getting SOC7 or SOC4 abend? List down the steps

714


1.Is it possible to move the data from 99.99 to 99v99? 2.What is the CICS-vsam Compilation process? 3.In My GDG 5 generation will be there GDG3 got an abend what will happen? 4.In my GDG first generation is +1 And I want to add the new generation what will happen previous generation? 5.How can you give the PIC clause below conditions A). s9 (reddy), B). s9 (5) occurs 5 times? 6.How override the proc from a particular step? and what is symbolic and override Procs?

5372


What are declaratives and what are their uses in cobol?

706


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

796






What kind of error is trapped by on size error option?

738


Which is the default, TEST BEFORE or TEST AFTER for a PERFORM statement?

818


Why would you use find and get rather than to obtain?

679


How do you code cobol to access a parameter that has been defined in jcl? And do you code the parm parameter on the exec line in jcl?

695


What is the use of intialize verb?

742


input= ,,,, mainframe training ,,, hyderabad .... location.... output1=$ mainframe training in hyderabad location$ output2=**** mainframe training in hyderabad location ****. In this pgn when we give input considering the spaces the output is displayed in this format.Like in the place of ,,,, $ should be displayed likewise.So please helpmeout.

1776


What is the difference between comp and comp-3 usage?

674


what is the use of outrecord?

1768


If you are current on the owner of a set, what is the difference between obtain next and obtain first?

639


What are the different rules to perform a Search?

613