Gather Stats taking too much time to complete
Having a table, sized around 155GB.
Script is given below to gather stats for the table.. It run more than 2 weeks thn also not completed. Then because of some batch process we forced to stop this scripts.
Need help for tuning the scripts to get better performance...
bash-3.2$ cat gather_stats_for_table_GL_JE_LINES.sql
-- vi gather_stats_for_table_GL_JE_LINES.sql
SET ECHO ON;
-- Spooling the log
SPOOL 'gather_stats_for_table_GL_JE_LINES.log';
-- Unlock the table
exec dbms_stats.unlock_table_stats(ownname=>'GL',tabname=>'GL_JE_LINES');
-- Gather Stats