Loading...
 

IndexPath

IndexPath

IndexPath(CX_xxxxx, pathExpression)

parameters: Identifier of a class, expression for an index path

Stack
Stack Position Description
Stack(In) Top -
Stack(Out) Top Index Path

An index path is a control data structure that enforces a specific order when a collection is accessed interactively.

Due to the page architecture of the database, it is not very effective to sort a collection by certain criteria. Instead, there is the tool Index path - a kind of operator applicable to collections that creates a "virtual sort".

The second operand defines the index path: An expression can be formed which ...

  1. corresponds to the possibilities given by ObjectStore, i.e. fixed data fields and query functions known in the database schema can be called.
  2. refers to dynamic data fields. Dynamic data fields, with which an index path is to be formed, must first be registered in CLASSIX.INI with the statement Index. The object class must be CX_EXPANDABLE or a class derived from it! It is not possible to build an index path with dynamic data fields for objects of the class CX_CONTAINER.
  3. With the pseudo function Retrieve, one or more InstantView® access expressions can be passed as parameters. Thus, a multi-level order can also be described.

The first operand is the class of objects to which the index path definition refers. The index path can only be applied to collections whose elements are objects of this or a derived class.

The FillObox,iterate and cursor instructions can be controlled with an index path (see example).