This content has been marked as final. Show 3 replies
am using 10g on Unix. With help from users on this site I was able to construct a stored procedure to gather stats and alter indices on a table that is populated and emptied twice within a process. If the stats aren't gathered after each population, the program will run for hours, rather than minutesYou can use parallel option to speed up gather stats job faster. and force as true ..
check this http://download.oracle.com/docs/cd/B19306_01/appdev.102/b14258/d_stats.htm
Using FORCE=>TRUE worked perfectly! The entire process ran in six minutes. It had been taking up to eight hours! I cannot thank you enough!!!
However if you have to use FORCE to gather stats, it means the statistics were locked, any reason ? You may want to investigate why they were locked before gathering stats on those objects.