View previous topic :: View next topic
|
Author |
Message |
tomrsan
New User
Joined: 15 Oct 2005 Posts: 13 Location: chennai
|
|
|
|
hi its san here
can anybody explain about the subcript and index detaily??? |
|
Back to top |
|
|
iknow
Active User
Joined: 22 Aug 2005 Posts: 411 Location: Colarado, US
|
|
|
|
Hi tomrsan,
I suggest you to search our forum first before you post.
Subscript
Subscript represents occurrence # of the Table Entry. Subscript can be represented explicitly and implicitly. Explicitly means thru occurrence # of the table entry; implicitly means thru a data name. That data name should be defined as an independent item in the W-S Section. The most efficient definition of Subscript is Full-Word binary.
INDEX
Index is assigned to specific table thru INDEXED BY clause. Internally is represented by Index Register which is Full-Word binary. Specific index name can be used to reference a field from the table to which that index is assigned to index represents displacement value of the table entry from the beginning of the table.
Difference between subscript and Index
[list=]A subscript is a working storage data definition item, typically a PIC (999) where a value must be moved to the subscript and then incremented or decremented by ADD TO and SUBTRACT FROM statements. An index is a register item that exists outside the program's working storage. You SET an index to a value and SET it UP BY value and DOWN BY value.
Index represent displacement value of the table entry from the beginning of the table, subscript - occurrence # of the table entry. To calculate the displacement of the table entry from its beginning when subscript is used takes 16 additional instructions from the system because of that the usage of the index is more efficient.[/list]
Please use the search option in our forum to get more details.
hope this helps. |
|
Back to top |
|
|
i413678 Currently Banned Active User
Joined: 19 Feb 2005 Posts: 112 Location: chennai
|
|
|
|
Hi,
Subscript can be changed by move and any arithematic verbs.
Index can only be changed by using set,search and perform.
Let me know if u know any......
Cheers...........................
pavan |
|
Back to top |
|
|
|