SQL/MP Reference Manual
HP NonStop SQL/MP Reference Manual—523352-013
C-108
Partition Attributes of Tables and Indexes
Partition Attributes of Tables and Indexes
If you convert a partitioned Enscribe file to a partitioned table, these rules apply:
The partitions of the table are derived from the partitions of the file. Each table
partition, other than the first one, is created on the same subvolume as the
corresponding file partition, unless you use the MAP NAMES option to override this
naming pattern.
The EXTENT and MAXEXTENTS physical attributes for each table partition are
derived from the corresponding Enscribe file partition.
For key-sequenced files, each Enscribe file partition's LOW KEY attribute is used
to derive the FIRST KEY attribute of the corresponding table partition. An Enscribe
LOW KEY value must be a valid FIRST KEY value in a CREATE TABLE
command.
Partitioned Enscribe alternate key files are converted to partitioned SQL indexes.
Examples—CONVERT
Suppose that you have a key-sequenced Enscribe file named ORDERTAB on
subvolume $VOL3.DDL. The contents of the Enscribe file are described by the
record definition ORDER. The record ORDER includes two DDL groups named
ORDERDATE and DELDATE. The record definition also indicates that the primary
key is ORDERNUM and that the alternate key field is CUSTNUM.
Here is the DDL record definition for the ORDER file:
RECORD ORDER.
FILE IS "$VOL3.DDL.ORDERTAB" KEY-SEQUENCED.
02 ORDERNUM PIC 9(3).
02 ORDERDATE.
03 MONTH PIC 9(2).
03 DAY PIC 9(2).
03 YEAR PIC 9(2).
02 DELDATE.
03 MONTH PIC 9(2).
03 DAY PIC 9(2).
03 YEAR PIC 9(2).
02 SALES-PERSON PIC X(4).
02 BRANCHNUM TYPE BINARY 32 NULL RaS VALUE IS 9999.
02 CUSTNAME.
03 LEN PIC S9(4) COMP.
03 VAL PIC X(30) VALUE IS "RINTERNALS".
02 CUSTNUM PIC 9(4).
02 STATUS PIC X(8) VALUE IS "RON HOLDS".
02 TOTAL-AMOUNT PIC 9(5)V9(2) NULL 0.
KEY IS ORDERNUM DUPLICATES NOT ALLOWED.
KEY "oc" IS CUSTNUM.
END
Suppose that your current default subvolume is $VOL3.DDL and that you want to
convert the Enscribe file ORDERTAB to a table named ORDERS on the