What is the difference between a subscript and an index in
a table definition?

Answer Posted / mftech

Subscript is the occurance number in the arrary of element.
Fr e.g., an array has only one itme that repeats for 20
times, in order to refer to 10th itme in this array, you
can say ITEM(20). This '20' can be replaced by a WS
variable having value = 20.

Index: It is the displacement from the begining. if you
remember, when we use Index in a loop, then we do not code
Move 2 to WS-INDEX. We have to code. We need to set the
index to zero and then increament.

Is This Answer Correct ?    7 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is amode(31)

724


What is the LINKAGE SECTION used in COBOL?

892


Have you used comp and comp-3 in your project? And how?

2009


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

644


which is Best IBM Mainframe Training and Placement Institute in Ameerpet Hyderabad

1024






What are the rules of the move verb?

708


How do u write test cases?

1639


What is the use of intialize verb?

750


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

1914


Name some of the examples of COBOl 11?

2687


what is amode(24), amode(31), rmode(24) and rmode(any)?

705


how do you reference the variable unblock file formats from cobol programs

750


How arrays can be defined in COBOL?

665


i want to learn mainframe..any websites and material to learn from basic..? my mail id : rajeswaribe2010@gmail.com

1773


how we sort two input files based on a common column and giving one o/p file please send me the coding logic?

1657