NonStop SQL/MP Reference Manual

Table Of Contents
NonStop SQL/MP Reference Manual142115
T-1
T
TABLECODE File Attribute
TABLECODE is a file attribute that assigns a numeric code to a table, index, or
collation. TABLECODE applies to key-sequenced, relative, and entry-sequenced files
and to indexes.
A table code is a numeric code chosen by the user to categorize files. The table code
appears in the TABLES and INDEXES catalog tables.
In output from the FILEINFO command and in contexts other than SQL, a table code is
referred to as a file code.
code>
is an integer value from 0 to 99 or from 1000 to 65535 that specifies the file code.
Values from 100 to 999 are reserved for use by Tandem.
Values from 571 to 599 are reserved for use by NonStop SQL/MP.
The table default is TABLECODE 0.
The index default is its table's value at index creation.
Tables
A table is a logical representation of data in a database in which a set of records is
represented as a sequence of rows, and the set of fields common to all records is
represented by columns. The intersection of a row and column represents the data value
of a particular field in a particular record.
All data in a NonStop SQL/MP database is stored in tables. Each table is described in a
NonStop SQL/MP catalog and stored in a physical file in the Guardian environment of a
Tandem NonStop system.
The description of a table includes the name of the table, the name of each column of the
table, the type of data you can store in each column of the table, and other information
about the table, including the physical characteristics of the file that stores the table.
In some descriptions of SQL, tables are referred to as base tables to distinguish them
from views, which are logical tables.
By default, SQL automatically opens partitions of tables and indexes as they are needed.
You can, however, use the CONTROL TABLE statement with the OPEN ALL option to
open all indexes and base partitions of a table the first time any partition is accessed.
See CREATE TABLE Statement
on page C-143 for more information about tables.
TABLECODE code