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 happens to the PLAN if index used by it is dropped?
List out the three types of page locks that can be held.
Name the different types of Table spaces.
When will you chose to run RUNSTATS?
What type of database is db2?
What is an instance in db2?
What is a DB2 plan?
i want to delete 20th million record how ?
What is a subselect? Is it different from a nested select?
What kind of database is db2?
What is a collection in db2?
Mention and explain the contention situations caused by locks?