日期:2014-05-16 浏览次数:20421 次
exp 用户名/密码@tns名 file=c:/test.dmp log=c:/test.log full=n rows=y buffer=10240000 tables=System.Test
create table system.Test_Bak tablespace ts_Test as select * from System.Test;
select count('x') c1 from System.Test; select count('x') c2 from System.Test_Bak;
truncate table System.Test; drop table System.Test;
create table System.Test tablespace ts_Test PARTITION BY RANGE(A) ( PARTITION P1 VALUES LESS THAN ('6') TABLESPACE TS_TEST , PARTITION P2 VALUES LESS THAN ('7') TABLESPACE TS_TEST, PARTITION P3 VALUES LESS THAN (MAXVALUE) TABLESPACE TS_TEST ) as select from System.Test_Bak;
select decode(A,'1','1','2','1','3','1','4','1','5','1',a), count('x') n from System.Test group by decode(A,'1','1','2','1','3','1','4','1','5','1',a) order by decode(A,'1','1','2','1','3','1','4','1','5','1',a); select count('x') n1 from System.Test partition (p1); select count('x') n2 from System.Test partition (p2);