本文共 2875 字,大约阅读时间需要 9 分钟。
NAME TYPE VALUE
------------------------------------ -------------------------------- ------------------------------db_block_buffers integer 0db_block_checking string FALSEdb_block_checksum string TRUEdb_block_size integer 8192SQL> show parameter db_16k_cache_size;NAME TYPE VALUE
------------------------------------ -------------------------------- ------------------------------db_16k_cache_size big integer 0SQL> alter system set db_16k_cache_size=1m;System altered.
SQL> create tablespace justin datafile '/data/oracle/oradata/justin/justin.dbf' size 10m blocksize 16k;
Tablespace created.
重新rebuild online一下
SQL> alter index idx_justin_name rebuild online tablespace justin; alter index idx_justin_name rebuild online tablespace justin ORA-00604: error occurred at recursive SQL level 1ORA-01450: maximum key length (3800) exceeded依旧不行,但是错误信息的max key length从3215上升到3800;SQL> drop tablespace justin;Tablespace dropped.
SQL> alter system set db_32k_cache_size=32k;
System altered.
SQL> create tablespace justin datafile '/data/oracle/oradata/justin/justin.dbf' size 10m blocksize 32k;
Tablespace created.
SQL> alter index idx_justin_name rebuild online tablespace justin;
alter index idx_justin_name rebuild online tablespace justin ORA-00604: error occurred at recursive SQL level 1ORA-01450: maximum key length (3800) exceeded使用块大小为32k和16k的表空间,均是报告3800为上限,依据提示将索引列的长度调小为3780,这次在32k表空间里可以创建成功,但是在其他8k表空间依旧不行SQL> alter table justin modify name varchar2(3780); Table altered SQL> alter index idx_justin_name rebuild online tablespace justin; Index altered SQL> alter index idx_justin_name rebuild online; Index altered SQL> alter index idx_justin_name rebuild online tablespace justin; alter index idx_justin_name rebuild online tablespace purchase ORA-00604: error occurred at recursive SQL level 1ORA-01450: maximum key length (3215) exceeded查看metalink ID 236329.1,
Rebuild the index without ONLINE clause. There is no way to rebuild this index ONLINE without the change of the initialization parameter db_block_size.ORRebuild the database with greater value of the initialization parameter db_block_size according to Note:136158.1: ORA-01450 and Maximum Key Length - How it is Calculated.以后遇到此类错误,
要么去掉online选项,要么创建blocksize更大的表空间;但是后者并不能保证一定可以rebulid online通过
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/15480802/viewspace-705231/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/15480802/viewspace-705231/