DBMS_STATS.gather_table_stats
Hi,
We are building a gather stats job and want to know..
Does DBMS_STATS.GATHER_TABLE_STATS checks for stale statistics before it processes the table? or do we have to check for stale statistics and run the command on them?
If we need to manually check for stale stats, would this SQL be enough?
select owner, table_name from dba_tab_statistics where stale_stats='YES' or last_analyzed is null;
Thanks