The PURGE_STATS procedure deletes historical statistics before a specified time.
Syntax
DBMS_STATS.PURGE_STATS(
before_timestamp TIMESTAMP WITH TIME ZONE);
Parameters
The before_timestamp parameter specifies the timestamp before which statistics are deleted. If NULL, the automatic purge strategy is used.
Exceptions
| Error Code | Description |
|---|---|
| HY000 |
|
Examples
Manually purge historical statistics before a specified time.
obclient [testUser01]> CALL DBMS_STATS.PURGE_STATS ('2021-09-26 19:02:12.675729');
Query OK, 0 rows affected
