Skip to main content

This is documentation for Caché & Ensemble.

For information on converting to InterSystems IRIS, see the InterSystems IRIS Adoption Guide and the InterSystems IRIS In-Place Conversion Guide, both available on the WRC Distributions page (login required).

Previous sectionNext section


Returns information about a select list.




listnum An expression that resolves to an integer between 1 and 10 (inclusive) that identifies a select list. This value is defined in the SELECT statement. listnum 0 is not valid for Caché MVBasic.
key An expression that resolves to an integer code indicating what select list information to return. The available values are 1 (active), and 3 (count).


The SELECTINFO function returns different values depending on the value of key:

  • If key is 1, SELECTINFO returns a boolean value, indicating whether the specified select list is active. 1=select list is active; 0=select list is inactive. A SELECT command activates a select list. When a READNEXT attempts to read past the last item of the select list, the list is inactivated.

  • If key is 3, SELECTINFO returns an integer value, specifying the total number of items in the select list. It returns 0 if the select list is not active, or if an active select list does not contain any items.


The following example uses the SELECTINFO function to return information about select list 4:

Copy code to clipboard

See Also