Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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 / venkat

when we define cobol table with OCCURS, it is of fixed
storage and length. The program execution will take the
total storage irrespective of utiliztaion. Where as table
degined with OCCURS DEPENDING ON provides flexibility to
the developers to choose length of table dynamically.
Length of below table is based on WS-OBJ value.

WS-SUB OCCURS 1 TO 5 TIMES DEPENDING ON WS-OBJ PIC X(2).

For example if you want to stoge employee detail in an
cobol table and you are not aware of number of employees at
the time of table declaration, you can use variable length
cobol table. During program execution based on number of
employees you can set the length of table

Is This Answer Correct ?    14 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How do you get the data to code the BMS macro?

1972


What is link edit in cobol?

1199


How to use the same COBOL program in Batch and CICS on lines? explain with an example

2395


What are the cobol coding sheets?

1275


How do you reference the following file formats from cobol programs?

1164


how do you define single dimensional array and multidimensional array in your cobol?

1106


How to find out the closest prime number of an input number? I believe it has something to do with SEARCH and COBOL Linear Array.

4173


Explain sorting techniques in cobol program? Provide the sort file definition, the sort statement, its syntax and meaning

1095


Can you please let me know the centre name of INS certification in Kolkata.

2245


What are the different data types in cobol?

1447


please..could u give an example about USAGE IS POINTER ..and explain why and when we use it ?

2472


) what is the difference between AID and HANDLE AID?

2159


how do you reference the ksds vsam file formats from cobol programs

1193


What is the difference between comp and comp-3?

1185


What is a scope terminator give example?

1113