Equinox Online Help - Language Reference - A to Z

Home

SetExecuteIndex

Applies to
SyntaxSetExecuteIndex IndexName, [GroupNumber, HowExpression, LowerLimit, UpperLimit]
Action[Statement] Sets the execution indexes for execute operations.
ScopeOnly usable in form methods or application methods.
Notes

This statement allows you to match a series of indexes with groups in the parameter file which is about to be executed. eg This allows you to apply indexes at run time prior to executing a report. The indexes are cleared after the execute statement.

IndexName is the index to use (applied to the table to which it belongs).

GroupNumber is a number between 1 and 16 - you can specify up to 16 separate indexes, one per table used. Equinox always matches the index specified to its table, so the indexes in the SetExecuteIndex list do not have to match the order of the tables used.

HowExpression may contain the following values:

  • 0 Every record (default)
  • 1 First
  • 2 Last
  • 3 Range

If HowExpression=3, the limit parameters are used. If one is missing, no limit is applied to that end.

The last 3 parameters are additions to Version 6 to bring this statement in line with other index controlling statements

The system workarea SysError is set to a non-zero value if an error occurs, otherwise zero.

CategoryIndexes
See Also BlankIndex, CopyIndex, CurrentIndex, GroupSetIndex, IndexFromName, IndexLastUsed, IsDuplicate, KeyValues, MakeKey, MarkIndex, ModifyIndex, NameFromIndex, SetIndex, UnmarkIndex, UpdateIndex
Example

The following example attaches indexes to 3 groups on a report prior to executing it. The report will include all customers within the A to C range, the last order for each customer and all items on that last order.

SetExecuteIndex Customergx, 1, 3, "A", "C"
SetExectuteIndex Orderscx, 2, 2
SetExecuteIndex Itemscx, 3, 0
Execute report "Order.rep"