About
Information about statistics structure (table, index,…)
Management
Metadata
- COL_STATS
Example: Stale statistics
SELECT
tstats.*,
tables.*
FROM
SYS.TABLES tables,
TBL_STATS tstats
WHERE
tables.tblid = tstats.tblid (+)
AND
(
laststatsupdate IS NULL
OR to_date(upper(SUBSTR(laststatsupdate,5)),'MON DD HH24:MI:SS YYYY') < sysdate - 7
)
AND tables.TBLOWNER <> 'SYS'
Update
procedure: ttOptUpdateStats