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 subscript and index?



What is the difference between subscript and index?..

Answer / robertd903

Subscripts are programmer-defined variables, of numeric type--used to reference an array.
Example:
77 WS-SUB PIC 9(04) COMP.
01 WS-TABLE.
05 WS-TABLE-ENTRY OCCURS 5 Times PIC X(80).

In PROCEDURE DIVISION:
MOVE WS-TABLE-ENTRY(WS-SUB) TO...

Indexes are defined by the programmer, but the PICTURE clause is omitted.
Example:
01 WS-TABLE.
05 WS-TABLE-ENTRY OCCURS 5 TIMES INDEXED BY WS-IDX.
10 FILLER PIC X(80).

In PROCEDURE DIVISION:
MOVE WS-TABLE-ENTRY(WS-IDX) TO...

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More COBOL Interview Questions

Should I use STOP RUN in the sub program??why?

6 Answers   Xansa,


What COBOL construct is the COBOL II EVALUATE meant to replace?

1 Answers  


What is file status 39 ?

10 Answers   JPMorgan Chase,


) How do you access the migrate the data from production region to development region

1 Answers   IBM,


What is different between variable length and fixed length?

2 Answers   TCS,


what is srange and nosrange pls reply to ths question ?

2 Answers   L&T,


What are the various section in data division and briefly explain them.

0 Answers  


What are the different forms of EVALUATE statement?

2 Answers   IBM, Micro Labs,


can anybody post me about file-aid and changemen tools pls and give me reference if any mainframe guys are there

0 Answers  


In my table having 3000 Records. How can I delete the 500th row? (we don't know what is data inside the table)

3 Answers   Keane India Ltd,


what will happen if pass values more than 100 using PARM parameter?

1 Answers  


Define REDEFINE clause and Is it possible to have the redefine clause anywhere in the working storage section for a data name?

3 Answers  


Categories