oracle??????????????
???????????? ???????[ 2017/4/20 10:51:32 ] ????????????? Oracle
????********************************************************************************
????5. ??????????
????********************************************************************************
????------------------------------------------------*
????5.1???????????
????------------------------------------------------*
????alter tablespace users coalesce;
????------------------------------------------------*
????5.2?????????
????------------------------------------------------*
????---????1:exo/imp??data pump????ü???
????---????2:CTAS
????create table newtable as select * from oldtable;
????drop table oldtable;
????rename table newtable to oldtable;
????----????3:move tablespace????
????alter table <table_name> move tablespace <newtablespace_name>;
????----????4:shrink
????alter table <table_name> enable row movement;
????alter table <table_name> shrink space cascade; --???????????????β??μ?HWM
????alter table <table_name> shrink space compact; --??????????μ?HWM???????DML????
????alter table <table_name> shrink space; --?μ?HWM?????DML????
????----????5:online redefinition
????--online redefinition???е???ó???:
????1).Online table redefinition enables you to:
????2).Modify the storage parameters of a table or cluster
????3).Move a table or cluster to a different tablespace
????4).Add or drop partitioning support (non-clustered tables only)
????5).Change partition structure
????6).Change physical properties of a single table partition?? including moving it to a different tablespace in the same schema
????7).Change physical properties of a materialized view log or an Oracle Streams Advanced Queueing queue table
????8).Add support for parallel queries
????9).Re-create a table or cluster to reduce fragmentation
????10).Convert a relational table into a table with object columns?? or do the reverse.
????11).Convert an object table into a relational table or a table with object columns?? or do the reverse.
????---???????
????--????1???????????а?????????ONLINE REDIFINITION????
????BEGIN
????DBMS_REDEFINITION.CAN_REDEF_TABLE('scott'??'t1'??
????DBMS_REDEFINITION.CONS_USE_PK);
????END;
????/
????--????2??????????????????
????create table scott.tp1 tablespace ocpyang
????as
????select * from scott.t1 where 1=2;
????--????3:???ONLINE REDIFINITION
????BEGIN
????DBMS_REDEFINITION.START_REDEF_TABLE('scott'?? 't1'??'tp1'??
????''??
????dbms_redefinition.cons_use_pk);
????END;
????/
????--????4:Copy dependent objects. (Automatically create any triggers?? indexes?? materialized view logs??
????grants?? and constraints on scott.tblorders.)
????DECLARE
????num_errors PLS_INTEGER;
????BEGIN
????DBMS_REDEFINITION.COPY_TABLE_DEPENDENTS('scott'?? 't1'??'tp1'??
????DBMS_REDEFINITION.CONS_ORIG_PARAMS?? TRUE?? TRUE?? TRUE?? TRUE?? num_errors);
????END;
????/
????--????5:???????primary??constraint???????
????select object_name?? base_table_name?? ddl_txt from
????DBA_REDEFINITION_ERRORS;
????--????6??Optionally?? synchronize the interim table hr.int_admin_emp.
????BEGIN
????DBMS_REDEFINITION.SYNC_INTERIM_TABLE('scott'?? 't1'?? 'tp1');
????END;
????/
????--????7??Complete the redefinition.
????BEGIN
????DBMS_REDEFINITION.FINISH_REDEF_TABLE('scott'?? 't1'?? 'tp1');
????END;
????/
????NOTE:
????The table scott.tblorders is locked in the exclusive mode only for a small window toward the end of this step.
????After this call the table scott.tblorders is redefined such that it has all the attributes of the scott.tptblorders table.
????------------------------------------------------*
????5.3 ???????????
????------------------------------------------------*
????alter index <index_name> rebuild online parallel 4 nologging;
????alter table <index_name> coalesce;
????????rebuild index????????????С?????????????????.??????rebuild index.
????********************************************************************************
????6.?????
????********************************************************************************
????1.?????????????????shrink?????????????????????????rebuild index??????
????2.???shrink???????????online redefinition????
????3.????????????rebuild index?????????coalesce????
????4.???shrink??rebuild index????????????????????????????????????????
????5.shrink???????????????????μ?HWM??????????????????μ?HWM???????
????6.????rebuild index???ONLINE????????????online.
???????????????????????漰???????????????????SPASVOС??(021-61079698-8054)?????????????????????????
??????
Oracle ??????????Oracle?????????????Oracle?????????????ORACLE_NUMBER????Scale?0??????????Oracle 11g R2 ????????????Oracle??????????????????Oracle ?????????(TSPITR)Oracle?????????????Oracle??????????????Oracle12.2?????????μ????????Oracle???????????????????Oracle???????????????????Oracle????MySQL?????????????oracle????????????????Oracle RAC?е????IP??????????Oracle?????????
???·???
??????????????????
2023/3/23 14:23:39???д?ò??????????
2023/3/22 16:17:39????????????????????Щ??
2022/6/14 16:14:27??????????????????????????
2021/10/18 15:37:44???????????????
2021/9/17 15:19:29???·???????·
2021/9/14 15:42:25?????????????
2021/5/28 17:25:47??????APP??????????
2021/5/8 17:01:11????????
?????????App Bug???????????????????????Jmeter?????????QC??????APP????????????????app?????е????????jenkins+testng+ant+webdriver??????????????JMeter????HTTP???????Selenium 2.0 WebDriver ??????