List Processing Commands

This section describes commands that create or process lists (other than those using English commands, which are listed here but described in English Commands). These lists, also known as select lists, usually consist of sets of item-ids. However, the meaning of each list entry depends on the command or program that uses the list.

Introduction

Overview

Lists exist in two states: active and saved. An active list is one that is ready for processing by the next input to be entered at the terminal. The active state of the list is indicated by the presence of the select prompt (>) on the terminal.

A saved list is one that is saved in a file item. Depending on the command you use to save the list, this can be in POINTER-FILE or another specified file. The system deletes an active list as soon as the next terminal input has been processed; you must delete a saved list explicitly.

List Generating Commands

A number of commands generate a list. These commands select data, generally item-ids, to create an active list. They do not display data but they do display the number of items in the list created. Commands that generate an active list are:

AND-ITEMS

AND-LISTS

BSELECT

ESEARCH

FORM-LIST

GET-LIST

ISELECT

NEW-GET-LIST

NSELECT

OR-ITEMS

OR-LISTS

QSELECT

SEARCH

SELECT

SELECT-INDEX

SSEARCH

SSELECT

XOR-ITEMS

XOR-LISTS

XSELECT

List Processing Commands

Other commands that process lists are:

CLEAR-LIST

COPY-LIST

DELETE-LIST

EDIT-LIST

NEW-SAVE-LIST

NEW-SORT-LIST

SAVE-LIST

SORT-LIST

The EDIT and SE editors can be used to edit lists saved in file items.

Types of List

Active List

An active list is indicated by a change from the TCL prompt (:) to the select prompt (>). The next input you enter at this new prompt can use the active list, after which the system deletes the active list, unless you have previously set the KEEPLIST option in your operating environment.

Saved List in POINTER-FILE

The SAVE-LIST command creates an item in POINTER-FILE containing the saved list. EDIT-LIST does the same thing if it is creating a new list.

The format of the item-id in the global POINTER-FILE file is:

account-name*L*list-name

where:

account-name is the name of the account with which the list is associated.

*L* identifies a list item.

list-name is the name of the saved list.

If you are using a local POINTER-FILE, the item-id is just list-name.

Default List (List with No Name)

Because the system generates a structured item-id for lists that it writes into the POINTER-FILE, it is possible to have a list with a null name. The list's item-id in the global POINTER-FILE has the form:

account-name*L*

In a local POINTER-FILE, the default list has a null item-id.

Examples

To copy all of the items in the file BP that begin with the letter B to another file called NEWBP, enter the following:

:SELECT BP = 'B]'
>COPY BP
TO:(NEWBP

To make and save a list of all of the items in the file BP that begin with the letter B and later use it to copy the items to another file called NEWBP, enter the following:

:SELECT BP = 'B]'
>SAVE-LIST BSOFBP
:
...
:GET-LIST BSOFBP
>COPY BP
TO:(NEWBP

The following example illustrates how to reference a list with no name:

:SELECT BP = 'B]'
>SAVE-LIST
:GET-LIST