guides:programming:programmers_reference_manual:openlist_command_format

OpenList Command Format

The primary OpenList commands share a general format, one that allows a very loose ordering of keyword clauses for a more natural usage.

The control keywords Only and Using are exceptional in this regard. Only has to appear just before or after the table specification, while the Using clause has to appear immediately after the table specification. This is illustrated in the format, which follows.

The specifications for the various keywords and information on how to use them are provided later in this chapter.

OpenList query statements are used primarily in reporting, but can be called from the BASIC+ RList subroutine.

Command [Only] [DICT] TableName [Using ALT_TABLENAME] [Selection] [Sort] [ [Control] Display [Override] ] [Format] [Modifier] [(Options)]

KeywordDescription
CommandCommand may be any of the following OpenList commands:

List
Sort
CountRows
SumRows
Select or SSelect
Display: If you are using the commands List or Sort, display is the column whose contents will appear in the report. You can display any number of columns in your report. Columns are displayed in the report according the order in which their names appear in the List or Sort command.
OnlyThe word Only instructs OpenList to display only the row keys in a table.
DictIf Dict is specified, the report will be generated against the dictionary portion of a table.
TableAny attached OpenInsight table. Table is the only argument that is required, other than the command itself.
UsingA Using clause specifies that the operation is to use the dictionary of the alternative table alt_table, rather than the table dictionary.
SelectionIf selection is specified, the command will select a subset of rows from table for processing. The selection.criteria are either a list of keys or a With clause (refer to the keyword With in this chapter).
SortIf sort is specified, the rows are displayed in a particular order (refer to the keyword By in this chapter).
ControlA keyword or words that affects the flow of control for the command. If specified, these may be any of the following:

Control Keyword : Description
Average : Produce a running average for a numeric value.
Break-on : Produce a "break" in the report when the value of a column changes.
Limit : Display only particular values out of a multi-valued column.
Only : List only the keys in a report.
Total : Produce subtotals and a grand total for a numeric column.

Each of these keywords is documented later in this chapter.

  • guides/programming/programmers_reference_manual/openlist_command_format.txt
  • Last modified: 2024/06/19 20:20
  • by 127.0.0.1