CREATE TABLE
Defines a new table.
Synopsis
CREATE [ [GLOBAL | LOCAL] {TEMPORARY | TEMP } | UNLOGGED] TABLE [IF NOT EXISTS]
<table_name> (
[ { <column_name> <data_type> [ COLLATE <collation> ] [<column_constraint> [ ... ] ]
[ ENCODING ( <storage_directive> [, ...] ) ]
| <table_constraint>
| LIKE <source_table> [ <like_option> ... ] }
| [ <column_reference_storage_directive> [, ...] ]
[, ... ]
] )
[ INHERITS ( <parent_table> [, ... ] ) ]
[ WITH ( <storage_parameter> [=<value>] [, ... ] ) ]
[ ON COMMIT { PRESERVE ROWS | DELETE ROWS | DROP } ]
[ TABLESPACE <tablespace_name> ]
[ DISTRIBUTED BY (<column> [<opclass>], [ ... ] )
| DISTRIBUTED RANDOMLY | DISTRIBUTED REPLICATED ]
{ --partitioned table using SUBPARTITION TEMPLATE
[ PARTITION BY <partition_type> (<column>)
{ [ SUBPARTITION BY <partition_type> (<column1>)
SUBPARTITION TEMPLATE ( <template_spec> ) ]
[ SUBPARTITION BY <partition_type> (<column2>)
SUBPARTITION TEMPLATE ( <template_spec> ) ]
[...] }
( <partition_specification> ) ]
} |
{ -- partitioned table without SUBPARTITION TEMPLATE
[ PARTITION BY <partition_type> (<column>)
[ SUBPARTITION BY <partition_type> (<column1>) ]
[ SUBPARTITION BY <partition_type> (<column2>) ]
[...]
( <partition_specification>
[ ( <subpartition_spec_column1>
[ ( <subpartition_spec_column2>
[...] ) ] ) ],
[ <partition_specification>
[ ( <subpartition_spec_column1>
[ ( <subpartition_spec_column2>
[...] ) ] ) ], ]
[...]
) ]
}
CREATE [ [GLOBAL | LOCAL] {TEMPORARY | TEMP} | UNLOGGED ] TABLE [IF NOT EXISTS]
<table_name>
OF <type_name> [ (
{ <column_name> WITH OPTIONS [ <column_constraint> [ ... ] ]
| <table_constraint> }
[, ... ]
) ]
[ WITH ( <storage_parameter> [=<value>] [, ... ] ) ]
[ ON COMMIT { PRESERVE ROWS | DELETE ROWS | DROP } ]
[ TABLESPACE <tablespace_name> ]
[ DISTRIBUTED BY (<column> [<opclass>], [ ... ] )
| DISTRIBUTED RANDOMLY | DISTRIBUTED REPLICATED ]
where column_constraint is:
[ CONSTRAINT <constraint_name>]
{ NOT NULL
| NULL
| CHECK ( <expression> ) [ NO INHERIT ]
| DEFAULT <default_expr>
| UNIQUE <index_parameters>
| PRIMARY KEY <index_parameters>
| REFERENCES <reftable> [ ( <refcolumn> ) ]
[ MATCH FULL | MATCH PARTIAL | MATCH SIMPLE ]
[ ON DELETE <key_action> ] [ ON UPDATE <key_action> ] }
[ DEFERRABLE | NOT DEFERRABLE ] [ INITIALLY DEFERRED | INITIALLY IMMEDIATE ]
and table_constraint is:
[ CONSTRAINT <constraint_name> ]
{ CHECK ( <expression> ) [ NO INHERIT ]
| UNIQUE ( <column_name> [, ... ] ) <index_parameters>
| PRIMARY KEY ( <column_name> [, ... ] ) <index_parameters>
| FOREIGN KEY ( <column_name> [, ... ] )
REFERENCES <reftable> [ ( <refcolumn> [, ... ] ) ]
[ MATCH FULL | MATCH PARTIAL | MATCH SIMPLE ]
[ ON DELETE <key_action> ] [ ON UPDATE <key_action> ] }
[ DEFERRABLE | NOT DEFERRABLE ] [ INITIALLY DEFERRED | INITIALLY IMMEDIATE ]
and like_option is:
{INCLUDING|EXCLUDING} {DEFAULTS|CONSTRAINTS|INDEXES|STORAGE|COMMENTS|ALL}
and index_parameters in UNIQUE and PRIMARY KEY constraints are:
[ WITH ( <storage_parameter> [=<value>] [, ... ] ) ]
[ USING INDEX TABLESPACE <tablespace_name> ]
and storage_directive for a column is:
compresstype={ZLIB|ZSTD|RLE_TYPE|NONE}
[compresslevel={1-19}]
[blocksize={8192-2097152} ]
and storage_parameter for the table is:
appendoptimized={TRUE|FALSE}
blocksize={8192-2097152}
orientation={COLUMN|ROW}
checksum={TRUE|FALSE}
compresstype={ZLIB|ZSTD|RLE_TYPE|NONE}
compresslevel={1-19}
fillfactor={10-100}
analyze_hll_non_part_table={TRUE|FALSE}
[oids=FALSE]
and partition_type is:
LIST | RANGE
and partition_specification is:
<partition_element> [, ...]
and partition_element is:
DEFAULT PARTITION <name>
| [PARTITION <name>] VALUES (<list_value> [,...] )
| [PARTITION <name>]
START ([<datatype>] '<start_value>') [INCLUSIVE | EXCLUSIVE]
[ END ([<datatype>] '<end_value>') [INCLUSIVE | EXCLUSIVE] ]
[ EVERY ([<datatype>] [<number> | INTERVAL] '<interval_value>') ]
| [PARTITION <name>]
END ([<datatype>] '<end_value>') [INCLUSIVE | EXCLUSIVE]
[ EVERY ([<datatype>] [<number> | INTERVAL] '<interval_value>') ]
[ WITH ( <partition_storage_parameter>=<value> [, ... ] ) ]
[ <column_reference_storage_directive> [, ...] ]
[ TABLESPACE <tablespace> ]
where subpartition_spec or template_spec is:
<subpartition_element> [, ...]
and subpartition_element is:
DEFAULT SUBPARTITION <name>
| [SUBPARTITION <name>] VALUES (<list_value> [,...] )
| [SUBPARTITION <name>]
START ([<datatype>] '<start_value>') [INCLUSIVE | EXCLUSIVE]
[ END ([<datatype>] '<end_value>') [INCLUSIVE | EXCLUSIVE] ]
[ EVERY ([<datatype>] [<number> | INTERVAL] '<interval_value>') ]
| [SUBPARTITION <name>]
END ([<datatype>] '<end_value>') [INCLUSIVE | EXCLUSIVE]
[ EVERY ([<datatype>] [<number> | INTERVAL] '<interval_value>') ]
[ WITH ( <partition_storage_parameter>=<value> [, ... ] ) ]
[ <column_reference_storage_directive> [, ...] ]
[ TABLESPACE <tablespace> ]
where storage_parameter for a partition is:
appendoptimized={TRUE|FALSE}
blocksize={8192-2097152}
orientation={COLUMN|ROW}
checksum={TRUE|FALSE}
compresstype={ZLIB|ZSTD|RLE_TYPE|NONE}
compresslevel={1-19}
fillfactor={10-100}
[oids=FALSE]
Description
CREATE TABLE creates an initially empty table in the current database.
The user who issues the command owns the table.
To be able to create a table, you must have the USAGE privilege on all column types or the type in the OF clause, respectively.
If you specify a schema name, Greengage DB creates the table in the specified schema. Otherwise, Greengage DB creates the table in the current schema. Temporary tables exist in a special schema, so you cannot specify a schema name when creating a temporary table. Table names must be distinct from the name of any other table, external table, sequence, index, view, or foreign table in the same schema.
CREATE TABLE also automatically creates a data type that represents the composite type corresponding to one row of the table.
Therefore, tables cannot have the same name as any existing data type in the same schema.
The optional constraint clauses specify conditions that new or updated rows must satisfy for an insert or update operation to succeed. A constraint is an SQL object that helps define the set of valid values in the table in various ways. Constraints apply to tables, not to partitions. You cannot add a constraint to a partition or subpartition.
Referential integrity constraints (foreign keys) are accepted but not enforced. The information is kept in the system catalogs but is otherwise ignored.
There are two ways to define constraints: table constraints and column constraints. A column constraint is defined as part of a column definition. A table constraint definition is not tied to a particular column, and it can encompass more than one column. Every column constraint can also be written as a table constraint; a column constraint is only a notational convenience for use when the constraint only affects one column.
When creating a table, there is an additional clause to declare the Greengage DB distribution policy.
If a DISTRIBUTED BY, DISTRIBUTED RANDOMLY, or DISTRIBUTED REPLICATED clause is not supplied, then Greengage DB assigns a hash distribution policy to the table using either the PRIMARY KEY (if the table has one) or the first column of the table as the distribution key.
Columns of geometric or user-defined data types are not eligible as Greengage DB distribution key columns.
If a table does not have a column of an eligible data type, the rows are distributed based on a round-robin or random distribution.
To ensure an even distribution of data in your Greengage DB system, choose a distribution key that is unique for each record, or if that is not possible, then choose DISTRIBUTED RANDOMLY.
If the DISTRIBUTED REPLICATED clause is supplied, Greengage DB distributes all rows of the table to all segments in the Greengage DB system.
This option can be used in cases where user-defined functions must run on the segments, and the functions require access to all rows of the table.
Replicated functions can also be used to improve query performance by preventing broadcast motions for the table.
The DISTRIBUTED REPLICATED clause cannot be used with the PARTITION BY clause or the INHERITS clause.
A replicated table also cannot be inherited by another table.
The hidden system columns (ctid, cmin, cmax, xmin, xmax, and gp_segment_id) cannot be referenced in user queries on replicated tables because they have no single, unambiguous value.
Greengage DB returns a column does not exist error for the query.
For more information about distribution, see Distribution.
The PARTITION BY clause allows you to divide the table into multiple sub-tables (or parts) that, taken together, make up the parent table and share its schema.
Though the sub-tables exist as independent tables, Greengage DB restricts their use in important ways.
Internally, partitioning is implemented as a special form of inheritance.
Each child table partition is created with a distinct CHECK constraint which limits the data the table can contain, based on some defining criteria.
The CHECK constraints are also used by the query optimizer to determine which table partitions to scan in order to satisfy a given query predicate.
These partition constraints are managed automatically by Greengage DB.
For more information about partitioning, see Partitioning.
Parameters
| Parameter | Description |
|---|---|
GLOBAL | LOCAL |
These keywords are present for SQL standard compatibility, but have no effect in Greengage DB and are deprecated |
TEMPORARY | TEMP |
If specified, the table is created as a temporary table.
Temporary tables are automatically dropped at the end of a session, or optionally at the end of the current transaction (see |
UNLOGGED |
If specified, the table is created as an unlogged table. Data written to unlogged tables is not written to the write-ahead (WAL) log, which makes them considerably faster than ordinary tables. However, the contents of an unlogged table are not replicated to mirror segment instances. Also an unlogged table is not crash-safe. After a segment instance crash or unclean shutdown, the data for the unlogged table on that segment is truncated. Any indexes created on an unlogged table are automatically unlogged as well |
table_name |
The name (optionally schema-qualified) of the table to be created |
OF <type_name> |
Creates a typed table, which takes its structure from the specified composite type (name optionally schema-qualified).
A typed table is tied to its type; for example the table will be dropped if the type is dropped (with When a typed table is created, the data types of the columns are determined by the underlying composite type and are not specified by the |
column_name |
The name of a column to be created in the new table |
data_type |
The data type of the column. This may include array specifiers. For table columns that contain textual data, specify the data type |
COLLATE <collation> |
The NOTE
GPORCA supports collation only when all columns in the query use the same collation. If columns in the query use different collations, then Greengage DB uses the Postgres planner. |
DEFAULT <default_expr> |
The |
ENCODING ( <storage_directive> [, …] ) |
For a column, the optional The clause is valid only for append-optimized, column-oriented tables. Column compression settings are inherited from the table level to the partition level to the subpartition level. The lowest-level settings have priority |
INHERITS ( <parent_table> [, …] ) |
The optional In Greengage DB, the If the same column name exists in more than one parent table, an error is reported unless the data types of the columns match in each of the parent tables. If there is no conflict, then the duplicate columns are merged to form a single column in the new table. If the column name list of the new table contains a column name that is also inherited, the data type must likewise match the inherited column(s), and the column definitions are merged into one. If the new table explicitly specifies a default value for the column, this default overrides any defaults from inherited declarations of the column. Otherwise, any parents that specify default values for the column must all specify the same default, or an error will be reported.
Column |
LIKE <source_table> [ <like_option> … ] |
The NOTE
Storage properties like append-optimized or partition structure are not copied. Default expressions for the copied column definitions will only be copied if Not-null constraints are always copied to the new table.
Indexes, Any indexes on the original table will not be created on the new table, unless the
Comments for the copied columns, constraints, and indexes will be copied only if
Note that unlike The |
CONSTRAINT <constraint_name> |
An optional name for a column or table constraint.
If the constraint is violated, the constraint name is present in error messages, so constraint names like NOTE
The specified |
NULL | NOT NULL |
Specifies whether the column is allowed to contain null values.
|
CHECK (<expression>) [ NO INHERIT ] |
The A constraint marked with Currently, |
UNIQUE (<column_constraint>) UNIQUE (<column_name> [, …]) (<table_constraint>) |
The For information about unique constraint management and limitations, see Notes |
PRIMARY KEY (<column_constraint>) PRIMARY KEY (<column_name> [, …]) (<table_constraint>) |
The For a table to have a primary key, it must be hash distributed (not randomly distributed), and the primary key, the column(s) that are unique, must contain all the columns of the Greengage DB distribution key.
In addition, the key must contain all the columns in the partition key if the table is partitioned.
Note that a key constraint in a partitioned table is not the same as a simple
For information about primary key management and limitations, see Notes |
REFERENCES <reftable> [ ( <refcolumn> ) ] [ MATCH FULL | MATCH PARTIAL | MATCH SIMPLE ] [ON DELETE | ON UPDATE] <key_action> FOREIGN KEY (<column_name> [, …]) |
The |
[NOT] DEFERRABLE |
The |
INITIALLY IMMEDIATE INITIALLY DEFERRED |
If a constraint is deferrable, this clause specifies the default time to check the constraint.
If the constraint is |
WITH (<storage_parameter>=<value>) |
The The defaults for some of the table storage options can be specified with the server configuration parameter The following storage options are available:
|
ON COMMIT |
The behavior of temporary tables at the end of a transaction block can be controlled using
|
TABLESPACE <tablespace> |
The name of the tablespace in which the new table is to be created |
USING INDEX TABLESPACE <tablespace> |
This clause allows selection of the tablespace in which the index associated with a |
DISTRIBUTED BY (<column> [<opclass>], [ … ]) DISTRIBUTED RANDOMLY DISTRIBUTED REPLICATED |
Declares the Greengage DB distribution policy for the table.
The Greengage DB server configuration parameter If the value of the parameter is
If the value of the parameter is set to
The |
PARTITION BY |
Declares one or more columns by which to partition the table. When creating a partitioned table, Greengage DB creates the root partitioned table (the root partition) with the specified table name. Greengage DB also creates a hierarchy of child tables that are the subpartitions based on the partitioning options that you specify. For each partition level, a partitioned table can have a maximum of 32,767 partitions. NOTE
Greengage DB stores partitioned table data in the leaf child tables, the lowest-level tables in the hierarchy of child tables for use by the partitioned table. |
partition_type |
Declares partition type: |
partition_specification |
Declares the individual partitions to create.
Each partition can be defined individually or, for range partitions, you can use the
|
SUBPARTITION BY |
Declares one or more columns by which to subpartition the first-level partitions of the table |
SUBPARTITION TEMPLATE |
Declares a subpartition template to be used to create subpartitions for all parent partitions |
Notes
-
In Greengage DB (a PostgreSQL-based system), the data types
VARCHARorTEXThandle padding added to the textual data (space characters added after the last non-space character) as significant characters; the data typeCHARdoes not.In Greengage DB, values of type
CHAR(n)are padded with trailing spaces to the specified widthn. The values are stored and displayed with the spaces. However, the padding spaces are treated as semantically insignificant. When the values are distributed, the trailing spaces are disregarded. The trailing spaces are also treated as semantically insignificant when comparing two values of data typeCHAR, and the trailing spaces are removed when converting a character value to one of the other string types. -
Greengage DB does not support using
WITH OIDSoroids=TRUEto assign an OID system column. Using OIDs in new applications is not recommended. This syntax is deprecated. As an alternative, use aSERIALor other sequence generator as the table’s primary key. However, if your application does make use of OIDs to identify specific rows of a table, it is recommended to create a unique constraint on the OID column of that table, to ensure that OIDs in the table will indeed uniquely identify rows even after counter wrap-around. Avoid assuming that OIDs are unique across tables; if you need a database-wide unique identifier, use the combination of table OID and row OID for that purpose. -
Greengage DB has some special conditions for primary key and unique constraints with regards to columns that are the distribution key in a Greengage DB table. For a unique constraint to be enforced in Greengage DB, the table must be hash-distributed (not
DISTRIBUTED RANDOMLY), and the constraint columns must be the same as (or a superset of) the table’s distribution key columns.Replicated tables (
DISTRIBUTED REPLICATED) can have bothPRIMARY KEYandUNIQUEcolumn constraints.A primary key constraint is simply a combination of a unique constraint and a not-null constraint.
Greengage DB automatically creates a
UNIQUEindex for eachUNIQUEorPRIMARY KEYconstraint to enforce uniqueness. Thus, it is not necessary to create an index explicitly for primary key columns.UNIQUEandPRIMARY KEYconstraints are not allowed on append-optimized tables because theUNIQUEindexes that are created by the constraints are not allowed on append-optimized tables.Foreign key constraints are not supported in Greengage DB.
For inherited tables, unique constraints, primary key constraints, indexes and table privileges are not inherited in the current implementation.
-
For append-optimized tables,
UPDATEandDELETEare not allowed in a repeatable read or serializable transaction and will cause the transaction to end prematurely.DECLARE … FOR UPDATEand triggers are not supported with append-optimized tables.CLUSTERon append-optimized tables is only supported over B-tree indexes. -
To insert data into a partitioned table, you specify the root partitioned table, the table created with the
CREATE TABLEcommand. You also can specify a leaf child table of the partitioned table in anINSERTcommand. An error is returned if the data is not valid for the specified leaf child table. Specifying a child table that is not a leaf child table in theINSERTcommand is not supported. Execution of other DML commands such asUPDATEandDELETEon any child table of a partitioned table is not supported. These commands must be run on the root partitioned table, the table created with theCREATE TABLEcommand. -
The default values for these table storage options can be specified with the server configuration parameter
gp_default_storage_options. The defaults includeappendoptimized,blocksize,checksum,compresstype,compresslevel, andorientation. The defaults can be set for the system, a database, or a user.
The current Postgres planner allows list partitions with multi-column (composite) partition keys. GPORCA does not support composite keys, so using composite partition keys is not recommended.
Examples
Create a table named rank in the schema named baby and distribute the data using the columns rank, gender, and year:
CREATE TABLE baby.rank
(
id int,
rank int,
year smallint,
gender char(1),
count int
)
DISTRIBUTED BY (rank, gender, year);
Create table films and table distributors (the primary key will be used as the distribution key by default):
CREATE TABLE films
(
code char(5)
CONSTRAINT firstkey PRIMARY KEY,
title varchar(40) NOT NULL,
did integer NOT NULL,
date_prod date,
kind varchar(10),
len interval hour to minute
);
CREATE TABLE distributors
(
did integer PRIMARY KEY DEFAULT nextval('serial'),
name varchar(40) NOT NULL CHECK (name <> '')
);
Create a gzip-compressed, append-optimized table:
CREATE TABLE sales
(
txn_id int,
qty int,
date date
)
WITH (appendoptimized = true, compresslevel = 5)
DISTRIBUTED BY (txn_id);
Create a simple, single-level partitioned table:
CREATE TABLE sales
(
id int,
year int,
qtr int,
c_rank int,
code char(1),
region text
)
DISTRIBUTED BY (id)
PARTITION BY LIST (code)
( PARTITION sales VALUES ('S'),
PARTITION returns VALUES ('R')
);
Create a three-level partitioned table that defines subpartitions without the SUBPARTITION TEMPLATE clause:
CREATE TABLE sales
(
id int,
year int,
qtr int,
c_rank int,
code char(1),
region text
)
DISTRIBUTED BY (id)
PARTITION BY LIST (code)
SUBPARTITION BY RANGE (c_rank)
SUBPARTITION BY LIST (region)
(
PARTITION sales VALUES ('S')
(
SUBPARTITION cr1 START (1) END (2)
(
SUBPARTITION ca VALUES ('CA')
),
SUBPARTITION cr2 START (3) END (4)
(
SUBPARTITION ca VALUES ('CA')
)
),
PARTITION returns VALUES ('R')
(
SUBPARTITION cr1 START (1) END (2)
(
SUBPARTITION ca VALUES ('CA')
),
SUBPARTITION cr2 START (3) END (4)
(
SUBPARTITION ca VALUES ('CA')
)
)
);
Create the same partitioned table as the previous table using the SUBPARTITION TEMPLATE clause:
CREATE TABLE sales1
(
id int,
year int,
qtr int,
c_rank int,
code char(1),
region text
)
DISTRIBUTED BY (id)
PARTITION BY LIST (code)
SUBPARTITION BY RANGE (c_rank)
SUBPARTITION TEMPLATE (
SUBPARTITION cr1 START (1) END (2),
SUBPARTITION cr2 START (3) END (4) )
SUBPARTITION BY LIST (region)
SUBPARTITION TEMPLATE (
SUBPARTITION ca VALUES ('CA') )
( PARTITION sales VALUES ('S'),
PARTITION returns VALUES ('R')
);
Create a three-level partitioned table using subpartition templates and default partitions at each level:
CREATE TABLE sales
(
id int,
year int,
qtr int,
c_rank int,
code char(1),
region text
)
DISTRIBUTED BY (id)
PARTITION BY RANGE (year)
SUBPARTITION BY RANGE (qtr)
SUBPARTITION TEMPLATE (
START (1) END (5) EVERY (1),
DEFAULT SUBPARTITION bad_qtr )
SUBPARTITION BY LIST (region)
SUBPARTITION TEMPLATE (
SUBPARTITION usa VALUES ('usa'),
SUBPARTITION europe VALUES ('europe'),
SUBPARTITION asia VALUES ('asia'),
DEFAULT SUBPARTITION other_regions)
( START (2009) END (2011) EVERY (1),
DEFAULT PARTITION outlying_years);
Compatibility
CREATE TABLE command conforms to the SQL standard, with the following exceptions:
-
Temporary tables — in the SQL standard, temporary tables are defined just once and automatically exist (starting with empty contents) in every session that needs them. Greengage DB instead requires each session to issue its own
CREATE TEMPORARY TABLEcommand for each temporary table to be used. This allows different sessions to use the same temporary table name for different purposes, whereas the standard’s approach constrains all instances of a given temporary table name to have the same table structure.The standard’s distinction between global and local temporary tables is not in Greengage DB. Greengage DB will accept the
GLOBALandLOCALkeywords in a temporary table declaration, but they have no effect and are deprecated.If the
ON COMMITclause is omitted, the SQL standard specifies that the default behavior asON COMMIT DELETE ROWS. However, the default behavior in Greengage DB isON COMMIT PRESERVE ROWS. TheON COMMIT DROPoption does not exist in the SQL standard. -
Column check constraints — the SQL standard says that
CHECKcolumn constraints may only refer to the column they apply to; onlyCHECKtable constraints may refer to multiple columns. Greengage DB does not enforce this restriction; it treats column and table check constraints alike. -
NULL constraint — the
NULLconstraint is a Greengage DB extension to the SQL standard that is included for compatibility with some other database systems (and for symmetry with theNOT NULLconstraint). Since it is the default for any column, its presence is not required. -
Inheritance — multiple inheritance via the
INHERITSclause is a Greengage DB language extension. SQL:1999 and later define single inheritance using a different syntax and different semantics. SQL:1999-style inheritance is not yet supported by Greengage DB. -
Partitioning — table partitioning via the
PARTITION BYclause is a Greengage DB language extension. -
Zero-column tables — Greengage DB allows a table of no columns to be created (for example,
CREATE TABLE foo();). This is an extension from the SQL standard, which does not allow zero-column tables. Zero-column tables are not in themselves very useful, but disallowing them creates odd special cases forALTER TABLE DROP COLUMN, so Greengage DB ignores this spec restriction. -
LIKE — while a
LIKEclause exists in the SQL standard, many of the options that Greengage DB accepts for it are not in the standard, and some of the standard’s options are not implemented by Greengage DB. -
WITH clause — the
WITHclause is a Greengage DB extension; neither storage parameters nor OIDs are in the standard. -
Tablespaces — the Greengage DB concept of tablespaces is not part of the SQL standard. The clauses
TABLESPACEandUSING INDEX TABLESPACEare extensions. -
Data distribution — the Greengage DB concept of a parallel or distributed database is not part of the SQL standard. The
DISTRIBUTEDclauses are extensions.