begin
DBMS_STATS.GATHER_TABLE_STATS('owner', 'table_name', estimate_percent=>50, block_sample=>TRUE, degree=>4) ;
end ;
or
ANALYZE TABLE <table_name> ESTIMATE STATISTICS 1000 ROWS;or
ANALYZE TABLE <table_name> ESTIMATE STATISTICS 50 PERCENT;
begin
DBMS_STATS.GATHER_TABLE_STATS('owner', 'table_name', estimate_percent=>50, block_sample=>TRUE, degree=>4) ;
end ;
ANALYZE TABLE <table_name> ESTIMATE STATISTICS 1000 ROWS;or
ANALYZE TABLE <table_name> ESTIMATE STATISTICS 50 PERCENT;