where can we use index and subscript ? with example ?
Answers were Sorted based on User's Feedback
Answer / tej
In addition to the above,
subscript is like a working storage variable
abc pic 999.
Using index the search for the data is faster since it gives
the object location(displacement) directly.
Subscript can be modified by ADD,SUBTRACT etc
Index modification is UP BY,DOWN BY
and yeah this q should have been in cobol section ;)
| Is This Answer Correct ? | 4 Yes | 1 No |
Answer / lu
Subscript refers to the array occurrence while index is the
displacement (in no of
bytes) from the beginning of the array. An index can only
be modified using PERFORM, SEARCH & SET.
Need to have index for a table in order to use SEARCH,
SEARCH ALL.
This is cobol, not DB2....
| Is This Answer Correct ? | 4 Yes | 2 No |
What does db2 mean?
Highlight all the advantages that are attached to a package.
What is the difference between dbm cfg and db cfg file in db2 ?
What is a collection?
the dd name for ksds is dest1 and what is the dd name for alternate index of ksds ? a.dest b.dest1 c.dest1a d.dd1
how to u check the query is executing or not ?where will u check for sqlcode ?
what is utility for parm lib
How to rename a table in DB2 ?
How to see the structure of db2 table??
Return code 100 means?
Why do we use cursor?
What is filter factor?