Write a program to concert an Indexed file into Sequential
file?
Answer / ajay ahuja
Program:
1. Define sequential file of same record size as of Indexed
file. say "WS-SEQ-FILE-RECORD".
2. Open Indexed file in INPUT mode and Sequential file in
output mode.
3. Read Indexed file into "WS-SEQ-FILE-RECORD".
4. Write into Sequential file. Continue Step 3 thru 4 until
end of Indexed file.
JCL:
Use Utility = IDCAMS,
//DD1 DD DSN=INDEXED.FILE.NAME
//DD2 DD DSN=SEQUENTIAL.FILE.NAME
// SYSIN DD *
REPRO INFILE(DD1) OUTFILE(DD2)
/*
//
I Hope this will help you !!!!
| Is This Answer Correct ? | 4 Yes | 0 No |
how we separate the cobol cics statements from cobol&cics programming?
The disposition parameter in the jcl is share ( DISP+SHR ) and the program opens file in extend mode what will happen?
How many maximum number of procedures can we write in one COBOL program?
If my file contains 100,000 records and job abended at 55,000th records processing then how can i restart job from that record onward by ignoring that record. I can not edit the file as file size is big and it is getting browse substituted?
can we read records in a file from botom to top. if possible how can we read
What are the different ways to run a COBOL DB2 program using JCL?
What are the various section in data division and briefly explain them.
how to know that the file has 300 records how to acess it?
what is jcl approach for programming?
How you can read the file from bottom?
how do you move only numeric data from A to B 01 A pic x(10) value 'a1b2c34d5e'. 01 B pic x(5).
what happens if we dont close cursor in db2-cobol pgm?