--
--  Table Rebuild script generated by TOAD 
--  
--  Original table: TT_JIAYU3
--  Backup of table: TT_JIAYU3_X
--  Date: 2004-8-23 17:27:06
--  
 
--  Lock original table before rename
 
LOCK TABLE TT_JIAYU3 IN EXCLUSIVE  MODE ; 
  
 
--  Make backup copy of original table
 
RENAME  TT_JIAYU3 TO TT_JIAYU3_X ; 
  
 
 
--  Remove all other NAMED Table Constraints because
--  they will cause errors when re-creating the table--  Recreate original table
 
CREATE TABLE D7I.TT_JIAYU3 ( 
  CHSNAME  VARCHAR2 (160), 
  PRIVS    VARCHAR2 (40) )
 TABLESPACE D7I_DATA PCTFREE 10
 STORAGE(INITIAL 64K NEXT K PCTINCREASE  ) ; 
  
 
--   Copy the data from the renamed table 
 
Insert into D7I."TT_JIAYU3" (
CHSNAME, PRIVS ) 
  SELECT 
CHSNAME, PRIVS
   FROM D7I."TT_JIAYU3_X" ; 
  
Commit ; 
  
--    Recreate indexes EXCLUDING those created via Unique Constraints
 
--    Recreate indexes EXCLUDING those created via Unique Constraints
 
 
--   Recreate the FKey Constraints from the NEW table
 
 
--   Grant any privs associated with the old table
 
 
--   Recreate the FKey Constraints that reference the NEW table 
 
 
--   Recompile any dependent objects
 
ALTER FUNCTION D7I.TEST_PRIVS COMPILE ; 
  
--  *** Recompile triggers for the new table
 
这是toad所产生的脚本