Currently I rebuild my indexes one at a time. ALter index rebuild.
Can anyone send me a script that will rebuild all my indexes all at once instead of just one at a time?
SQL> spool rebuil.lst
SQL> select 'alter','index',index_name,'rebuild',';'
SQL> from dba_indexes where
SQL> owner='<OWNER NAME>' ;
SQL> spool off
open the "rebuild.lst" file
remove all the lines excepting those starting with "alter"
save the file as <filename>.sql
Now Run the file
There is a small correction in the last post
i will post you very good solution soon
set pages 1000
set lines 1000
set echo off
set heading off
set feedback off
SELECT 'ALTER INDEX '||owner||'.'||index_name||' REBUILD;'
WHERE owner = 'SCOTT';
'REBUILD' is not an option on the lower versions of 734. Just a reminder.
I don't know in which 7.3 version it's introduced, but before 7.3.4. It works in 18.104.22.168.
[Edited by akkerend on 02-06-2001 at 01:44 PM]
Click Here to Expand Forum to Full Width