LOCK_CATALOG_TABLE_STAT is used to lock external table statistics in the catalog.
Note
This subprogram is available starting with V5.0.1.
Syntax
DBMS_STATS.LOCK_CATALOG_TABLE_STAT (
catname VARCHAR(65535),
dbname VARCHAR(65535),
tabname VARCHAR(65535),
partname VARCHAR(65535) DEFAULT NULL,
stattype VARCHAR(65535) DEFAULT 'ALL'
);
Parameters
Parameter |
Explanation |
|---|---|
| catname | Specifies the catalog name. |
| dbname | Specify the database name. |
| tabname | Specifies the name of the table to lock. |
| partname | Specifies the partition name.NULLRepresents the entire table. |
| stattype | Specifies the type of information to be locked, that is, which category of statistics to lock. Valid values:
|
Examples
Lock all statistics information of the lineitem table in the hive_catalog catalog and the test_oss database. The lock type is ALL.
obclient> CALL DBMS_STATS.GATHER_CATALOG_TABLE_STATS (
'hive_catalog',
'test_oss',
'lineitem',
NULL
'ALL'
);
