CREATE CATALOG "catalog" UNDER data-service
[ NATIVE NAME native-name ]
[ create-catalog-options ]
Specifies a logical catalog name. Surround the catalog name in double quotation marks.
Specifies the data service name under which the catalog is to be created.
Specifies the native catalog name if the native catalog name is not unique within the server. The native name is used resolve catalog name collisions between multiple data services that support catalogs. Client SQL always references the catalog through the logical catalog name regardless of whether a native name is specified. The native catalog is treated as a missing value if it reflects the same name as the logical catalog.
Specifies the options to create a catalog. This option only applies to the BASE data service.
create-catalog-options ::= create-catalog-options::= conopts-configuration-list
If DRIVERdriver-name
is omitted, the default driver for the data service is assumed. Associated options within the CONOPTS
list are used
for connections using the appropriate driver. The multiple driver
syntax is not supported.
conopts-configuration-list::= CONOPTS "(" [DRIVERdriver-name] ["," driver-connection-string-option ...] ")" ...
Specifies the driver name.
Specifies the connection options that correspond to the specified driver. For a list of valid connection string options, see the driver reference topic for your specific data source.
CREATE CATALOG "catalog1_BASE" UNDER BASE
CREATE CATALOG "TKTEST" UNDER SQLServer1
CREATE CATALOG "Catalog1" UNDER SQLServer1 NATIVE NAME "TKTEST"
CREATE CATALOG "c1" UNDER BASE {OPTIONS conopts (COMPRESS YES)}
ALTER CATALOG "catalog" RENAME TO "newcatalogname"
ALTER CATALOG "catalog"
[ NATIVE NAME "native-name" ]
[ alter-catalog-options ]
Specifies the name of the existing catalog.
Specifies the new catalog name.
Specifies the name of the native catalog.
Specifies the options to alter the catalog. This option only applies to the BASE data service. The syntax for alter-catalog-options is the same as the syntax for alter-generic-options. All create-catalog-options are also supported.
ALTER CATALOG "catalog3_BASE" RENAME TO "catalog3_BASE_RENAME"
ALTER CATALOG "Catalog3" NATIVE NAME "TKTEST3_RENAME"
ALTER CATALOG "catalog1_BASE" {OPTIONS add CONOPTS(DRIVER BASE, ACCESS READONLY)}
ALTER CATALOG "catalog1_BASE" {OPTIONS set (CONOPTS(DRIVER BASE, ACCESS READONLY))}
ALTER CATALOG "catalog1_BASE" {OPTIONS xset CONOPTS(DRIVER BASE, COMPRESS YES)}
ALTER CATALOG "catalog1_BASE" {OPTIONS drop CONOPTS(DRIVER BASE)}
DROP CATALOG "catalog" [ drop-disposition ]
Specifies the catalog name. Catalog name requires double quotation marks.
drop-disposition ::=
{RESTRICT | CASCADE} [FORCE]
Specifies a drop disposition as one of the following values:
RESTRICT | Specifies that the drop target is empty. This is the default value. |
CASCADE | Specifies that container objects are dropped. |
FORCE | Specifies the optional FORCE keyword that will suppress error messages when the data service does not exist. This additional option does not affect the performance of the RESTRICT or CASCADE options. |
DROP CATALOG "catalog3"
DROP CATALOG "catalog1_base" cascade
CREATE SCHEMA [ "catalog"."schema"]
[ AUTHORIZATION|OWNER owner ]
[ create-schema-options ]
Specifies the optional catalog name under which to create the schema. This is useful for data sources that support catalog names. For those that do not, the catalog name must be the logical catalog name which defaults to the name of the data service.
Specifies the name of the schema.
Authorization identifier
of the schema owner. If the AUTHORIZATION
clause
is not specified, schema ownership defaults to the SYSTEM
user
account. However, schema ownership by the SYSTEM
user
account could present problems with FedSQL views and data cache.
Specifies an option list for the schema.
create-schema-options ::=
"{" OPTIONS ["("] schema-option
[ { "," schema-option } ... ] [")"] "}"
Specifies the syntax for schema options. This option only applies to the BASE data service.
If DRIVER driver-name
is omitted, the default driver for the data service is assumed. Associated options
within the CONOPTS
list are used
for connections using the appropriate driver.
conopts-configuration-list ::= CONOPTS "(" [DRIVER driver-name] [","driver-connection-string-option ...] ")"...
Specifies the driver name.
Specifies the connection options that correspond to the driver which is specified
in DRIVERdriver-name
. For a list of valid connection string options, see the driver reference topic for
your specific data source.
Specifies the physical location for the SAS library, which is a collection of one or more SAS files. For example, in directory-based operating environments, a SAS library is a group of SAS files that are stored in the same directory. This option is required for BASE schemas.
PRIMARYPATH path ::=
quoted-identifier
Specifies a single quoted or double quoted name.
CREATE SCHEMA "catalog1_BASE"."schema1_BASE" {OPTIONS (primarypath 'C:\schema1_BASE')}
CREATE SCHEMA "ORACLE1"."TKTSTST1"
CREATE SCHEMA "catalog1"."schema1" {OPTIONS primarypath 'C:\my_schema', conopts (LOCKTABLE EXCLUSIVE)}
ALTER SCHEMA [ "catalog"."schema" ] RENAME TO "newschema"
ALTER SCHEMA [ "catalog"."schema" ] AUTHORIZATION|OWNER TO owner
[ create-if option ]
ALTER SCHEMA [ "catalog"."schema" ]
[ alter-schema-options ]
Specifies the catalog name.
Specifies the schema name to change.
Specifies the new schema name.
Specifies what options to alter in the schema.
alter-schema-options ::=
"{" OPTIONS ["("] alter-schema-option
[{"," alter-schema-option} ... ] [")"]"}"
Specifies the schema option to alter. This option only applies to the BASE data service.
alter-schema-option ::=
[DROP schema-option-name ] [{ADD | SET} schema-option ] [create-if-option
Specifies the syntax for schema options.
If DRIVERdriver-name
is omitted, the default driver for the data service is assumed. Associated options
within the CONOPTS
list are used
for connections using the appropriate driver.
conopts-configuration-list ::= CONOPTS "(" [DRIVER driver-name] ["," driver-connection-string-option ...] ")" ...
Specifies the driver name.
Specifies the connection options that correspond to the driver which is specified
in DRIVERdriver-name
. For a list of valid connection string options, see the driver reference topic for
your specific data source.
Specifies the physical location for the SAS library, which is a collection of one or more SAS files. For example, in directory-based operating environments, a SAS library is a group of SAS files that are stored in the same directory. This option applies to BASE schemas only and is required.
path ::= quoted-identifier
Specifies a single quoted or double quoted name.
Creates the schema if it does not already exist using the remaining options.
create-if-option
CREATE_IF N[O]|F[ALSE]|OFF|0|Y[ES]|T[RUE]|ON|1
ALTER SCHEMA "catalog1_BASE"."schema3_BASE" RENAME TO "schema3_BASE_RENAME"
ALTER SCHEMA "catalog1_BASE"."schema3_BASE" {OPTIONS set primarypath 'C:\mydir'}
ALTER SCHEMA "catalog1_BASE"."schema3_BASE" {OPTIONS add conopts (LOCKTABLE SHARE)}
DROP SCHEMA [ "catalog"."schema" ] [ drop-disposition ]
Specifies the catalog name.
Specifies the schema name.
Specifies the drop disposition and is one of the following values:
drop-disposition ::=
{RESTRICT | CASCADE} [FORCE]
RESTRICT | Specifies that the drop target is empty. This is the default value. |
CASCADE | Specifies that contained objects are dropped. |
FORCE | Specifies the optional FORCE keyword that will suppress error messages when the data service does not exist. This additional option does not affect the performance of the RESTRICT or CASCADE options. |
DROP SCHEMA "catalog1_BASE"."schema1_BASE"
DROP SCHEMA "catalog1_BASE"."schema1_BASE" force