Skip to main content

LOCK_PARTITION_STATS

The LOCK_PARTITION_STATS procedure is used to lock the statistics of a partition.

DBMS_STATS.LOCK_PARTITION_STATS (
ownname VARCHAR2,
tabname VARCHAR2,
partname VARCHAR2);

Parameters

ParameterDescription
ownnameThe username. If the username is set to NULL, the current login username will be used by default.
tabnameThe table name.
partnameThe name of the table (sub)partition.

Usage

You must be the owner of the table to call this procedure.

Examples

Lock the statistics of the p0 partition of the t1 table for the user testUser01.

CALL DBMS_STATS.LOCK_PARTITION_STATS('testUser01', 't1', 'p0');
Query OK, 0 rows affected