Skip to main content

This is documentation for Caché & Ensemble. See the InterSystems IRIS version of this content.

For information on migrating to InterSystems IRIS, see Why Migrate to InterSystems IRIS?

$ZSORT (legacy function) (ObjectScript)

Returns the next subscript in the array of the specified subscripted variable.




Argument Description
variable A subscripted local or global variable. The subscript is required; you cannot specify just the array name.
direction Optional — The subscript order in which to traverse the target array. Use 1 (the default) for ascending subscript order and -1 for descending subscript order.


This page describes the legacy function $ZSORT. It is described here for compatibility with legacy applications. $ZSORT is identical to the $ORDER function in Caché, which is the function call that should be used for new applications.

$ZSORT returns the next subscript in the subscripted variable. The variable parameter can specify a subscripted local or global variable.

See Also