All Products
Search
Document Center

PolarDB:dbms_sql.flush_trace

Last Updated:Mar 28, 2026

dbms_sql.flush_trace is a stored procedure that clears all SQL Trace statistics and trace records from the information_schema.sql_sharing system table.

Syntax

dbms_sql.flush_trace()

No parameters.

Flush trace records

Run the following statement to clear all SQL Trace statistics and trace records:

call dbms_sql.flush_trace();

Verify the flush

Query information_schema.sql_sharing to confirm the records have been cleared:

select * from information_schema.sql_sharing\G

Expected output:

Empty set (0.00 sec)