The DELETE_TABLE_PREFS procedure deletes a statistics preference for a table owned by the specified user.
Applicability
This topic applies only to OceanBase Database Enterprise Edition. OceanBase Database Community Edition provides only the MySQL mode.
Syntax
DBMS_STATS.DELETE_TABLE_PREFS (
ownname IN VARCHAR2,
tabname IN VARCHAR2,
pname IN VARCHAR2);
Parameters
| Parameter | Description |
|---|---|
| ownname | The username. If the parameter is set to NULL, the current login username is used by default. |
| tabname | The name of the table. |
| pname | The name of the preference. |
Exceptions
| Error code | Description |
|---|---|
| OBE-20000 | You do not have the required privileges. |
| OBE-20001 | The input value is invalid. |
Considerations
To call this procedure, you must connect to the database as the specified user, or have the
SYSDBAprivilege.The parameters of this procedure are of the
VARCHAR2type and their values must be enclosed with parentheses.
Examples
Delete the DEGREE preference for the tbl1 table of the testUser01 user.
obclient> CALL DBMS_STATS.DELETE_TABLE_PREFS('testUser01', 'tbl1', 'DEGREE');
Query OK, 0 rows affected