Sunday, May 15, 2016

Oracle schema statistics gathering


set echo on;                                                                                                                                                                                                                                                                                              

set feedback on;                                                                                                                                                                                                                                                                                          

spool /export/home/gather_schema_stats.log;                                                                                                                                                                                                                    

EXEC DBMS_STATS.GATHER_SCHEMA_STATS(OWNNAME=>'MYNATRACE_PROD',CASCADE=>TRUE, ESTIMATE_PERCENT=>DBMS_STATS.AUTO_SAMPLE_SIZE,DEGREE=>8);                                                                                                                                                                      

spool off;                                                                                                                                                         

No comments:

Post a Comment