Assume a Database with four levels and each level has only one Segement-type.i.e, (A-->B--->C---D) and assume that one-to-one relationship in consecutive levels. That is,
A1-->B1--->C1---D1
A2-->B2--->C2---D2
A3-->B3--->C3---D3 and so on.
a. Assume that position is established in C10. If we issue GU call with unqualified SSA in all levels , which occurance will it retrieve in "D". Is it D1 or D10 ?.
b. Manual says "If IMS has a position established at the missing level, the SSA that IMS uses is derived from that position, as reflected in the DB PCB.". I assumed that this point is applicable for only segments with Key fields.
C. Assume that position is established at A10. If I issue GU call with unqulified SSA for "A" segment, which occurance of segment "A" will be retrieved. Is it A1 or A10 ?.
Suppose there is no key in segment "C" and position is established at that level. If we issue GU call with qualified SSA in first 2 levels and unqualified SSA in third level, how SSA for "C" will be built ?.
Following statements are taken from IBM manual related to GU call.
If you leave out an SSA for one of the levels in a GU call that has multiple SSAs, IMS assumes an SSA for that level. The SSA that IMS assumes depends on current position:
a.If IMS has a position established at the missing level, the SSA that IMS uses is derived from that position, as reflected in the DB PCB.
b.If IMS does not have a position established at the missing level, IMS assumes an unqualified SSA for that level.
c.If IMS moves forward from a position established at a higher level, IMS assumes an unqualified SSA for that level.
d.If the SSA for the root level is missing, and IMS has position established on a root, IMS does not move from that root when trying to satisfy the call.