what is the difference between occurs and occurs depending
on? i dont think so there is the difference in
storage..then why we should use occurs depending on?

Answer Posted / sivakumar sekharannair

As ram said the number of occurances stored can be only 5
in either case. it cannot exceed more than that. what i
feel is when the first occurs clause is used regardless of
the number of occurances are loaded in the table the memory
allocation would be 5 bytes but if occurs 1 to 5 times
depending on ws-var, memory allocation will be made based
on the number of occurances loaded.

Is This Answer Correct ?    4 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

I need to compare 3 variables(dates) and do some processing based on the earliest date. There could be more then 1 date record in any of the 3 fields. What is the best way to code this?

1808


What are 77 levels used for?

660


How to fetch 1000 error records from VSAM file(Eg: 1000000 records present) while getting SOC7 abend ?

1946


How can you get the ksds file records into your cobol program?

644


if we have " ibm mainframe ",in that how to remove first and last leading space eg:"ibm mainframe" like that the answer we need

859






Give some examples of command terminators?

759


INREC AND OUTREC? HOW TO SPLIT 5K RECORDS TO DIFFERENT FILES IN A FILE IN COBOL? RESTART IN COBOL-DB2? ISOLATION LEVELS?

424


Define static linking and dynamic linking.

669


What is the Purpose of POINTER Phrase in STRING command in COBOL?

721


Mention the guidelines to write a structured cobol program?

620


I have File 1 occurs 5 times with Employee-ID,Employee-Name,Employee-Dept (EEE and MECH). I have File 2 occurs 10 times with Employee-ID,Employee-Name,Employee-Dept (EEE,CIVIL,CHEMICAL and MECH). In FIle 1 and FIle 2 , for matching Employee-DEPT (Only MECH) , we need to move entire records from file1 to file 2. We should not use 2D array. Your help is needed here.

1119


How can we find that module can be called – whether DYNAMICALLY or STATICALLY?

714


What guidelines should be followed to write a structured cobol prgm?

673


what are decleratives in cobol?

1828


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

712