Why occurs can not be used in 01 level ?
Answers were Sorted based on User's Feedback
Answer / anil prajapati
occurs can not be define at 01 level because records never
repeated only fields are repeated
| Is This Answer Correct ? | 15 Yes | 1 No |
Answer / nitin
if we put occut at 01 level record will be repeated not
fields.
| Is This Answer Correct ? | 3 Yes | 1 No |
Explain fixed length record in cobol? with suitable example
Suppose i have a Cobol field of 10 byte. it contains a decimal sign.How to know where is the point location?
Have you used comp and comp-3 in your project? And how?
How much salary you are expecting? If they ask in an interview, what we have to tell?
6 Answers Tech Mahindra, Wipro,
How to declare if emp-name = AAAAA""BBB in working-storage section. After display emp-name should print like AAAAA""BB
How to resolve the soc4 and soc7 errors?
in real time what is the suitable exp where in-stream procedure is better then catalog procedure.
in cobol main pgm is calling sub pgm but sub pgm does not exists , what abend i get if submit the job?
If i have a variable A pic 9(2) value 10 Compute A = a - 100 what will be the value of A and will there be any error becoz of the Negative value
When is a scope terminator mandatory?
How do you submit JCL via a Cobol program?
I have PS flat file with 14 records. I want to read from 4th to 9th record and want to write those 6 records (4th record to 9th record) to another PS file (output file). there is no key defined in the input file. I just want read a certain Consecutive records. can any one please give me the procedure division Coding for this. I have coded the below coding but the READ-PARA is performing only 1 time even though I have 14 records in my input file (i.e FILE-1): PROCEDURE DIVISION. A000-SECTION. MOVE 0 TO I. OPEN INPUT FILE-1. IF CHECK-KEY1 > 0 DISPLAY "OPEN ERROR FOR FILE-1, CODE IS:" CHECK-KEY1 END-IF. OPEN EXTEND NEWFILE-1 IF CHECK-KEY3 > 0 DISPLAY "OPEN ERROR FOR NEWFILE-1 COD IS" CHECK-KEY3 END-IF. PERFORM READ-PARA THRU EXIT-PARA UNTIL EOF-REC = 'YES'. DISPLAY " FINALLY OUT OF LOOP" CLOSE FILE-1 CLOSE NEWFILE-1 STOP RUN. READ-PARA. ADD 1 TO I READ FILE-1 AT END MOVE 'YES' TO EOF-REC IF I > 3 AND < 10 PERFORM WRITE-PARA ELSE DISPLAY "NOT IN RANGE" END-IF. EXIT-PARA. EXIT. WRITE-PARA. WRITE NEW-REC FROM FILE1-REC.