ListLinkingFields (map pairs of linked fields)

Top  Previous  Next


ListLinkingFields( relationmanager, fieldpairs [, recursed] )


Maps pairs of linking fields between the primary file and a related file.


The label of the related file's RelationManager object.


The label of the FieldPairsClass object to receive the linking field references.


A numeric constant, variable, EQUATE, or expression that indicates whether this method was called by itself (recursive). A value of zero (0) indicates a non-recursive call; a value of one (1) indicates a recursive call. This allows the method to get the list of linking fields from the relationmanager if necessary--since only one side of the relationship maintains the list of linking fields. If omitted, recursed defaults to zero (0). You should always omit this parameter when calling the ListLinkingFields method from your program.

The ListLinkingFields method maps pairs of linking fields between the primary file and a related file.


The RelationManager object does not use the resulting mapped fields, but provides this mapping service for the ViewManager class, etc.


ViewManager.AddRange PROCEDURE(*? Field,RelationManager MyFile,RelationManager HisFile)

CODE                                             !add range limit to view

SELF.Order.LimitType = Limit:File                !set limit type: relationship

!get linking fields


ASSERT(RECORDS(SELF.Order.RangeList.List))       !confirm Range limits exist

SELF.SetFreeElement                              !set free key element