next up previous contents index
Next: Specifying Pixels in Up: MIDAS Data Structures Previous: Specifying Keywords

Specifying Elements in a Table

  

The MIDAS table file system is described in detail in chapter 5 of this volume. Here we just explain briefly how to access the various elements in a table file. To do so, it is necessary to specify the table name, the column and the row. This is done in the following format:

table column row

where
table is the table name;
column is the desired column which can be referenced by label as :col or by sequence number as #n;
row is the desired row referenced by number as @n or by a value in a predefined reference column.
Like descriptor and keyword names, column labels are case insensitive. The command:

READ/TABLE tname #3 @10

would display the element in column 3 of row 10 in table file tname.tbl .
Similarly, the command:

READ/TABLE tname :MAGNITUDE 20.0

would access the element in the column labeled `MAGNITUDE' and value 20.0 in the reference column (this reference column must have been defined before via the SET/REF command).
Note, that we need not specify the file extension .tbl as in the descriptor related commands. All table commands default the data files to tables with extension .tbl.

Single table elements can also be written in a more direct way, via
table,column,row = value, e.g. to set the element in the 3rd row of the column labeled :XREF in the table lola.tbl to 1.234, use lola,:xref,@3 = 1.234
The value can also be an expression made up of constants and elements of any MIDAS data structure, see the subsection gif.

Some of the commands dealing with tables are: READ/TABLE, WRITE/TABLE, COMPUTE/TABLE, SHOW/TABLE, EDIT/TABLE, COPY/TABLE.



next up previous contents index
Next: Specifying Pixels in Up: MIDAS Data Structures Previous: Specifying Keywords



Pascal Ballester
Fri Mar 24 17:17:52 MET 1995