@ -1167,7 +1167,8 @@ static List* AddDefaultOptionsIfNeed(List* options, const char relkind, CreateSt
|
||||
stmt->relation->relpersistence == RELPERSISTENCE_TEMP ||
|
||||
stmt->relation->relpersistence == RELPERSISTENCE_GLOBAL_TEMP;
|
||||
if (noSupportTable && tableCreateSupport.compressType) {
|
||||
ereport(ERROR, (errcode(ERRCODE_INVALID_OPTION), errmsg("only row orientation table support compresstype.")));
|
||||
ereport(ERROR, (errcode(ERRCODE_INVALID_OPTION), errmsg("compresstype can not be used in ustore table, segment table, "
|
||||
"column table, view, unlogged table or temp table.")));
|
||||
}
|
||||
CheckCompressOption(&tableCreateSupport);
|
||||
|
||||
@ -14729,9 +14730,13 @@ static void ATExecSetRelOptions(Relation rel, List* defList, AlterTableType oper
|
||||
errmsg("\"%s\" is not a table, view, materialized view, index, or TOAST table", RelationGetRelationName(rel))));
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
if (rel->rd_options && REL_SUPPORT_COMPRESSED(rel)) {
|
||||
SetupPageCompressForRelation(&rel->rd_node, &((StdRdOptions *)(rel->rd_options))->compress,
|
||||
RelationGetRelationName(rel));
|
||||
}
|
||||
CheckSupportModifyCompression(rel, relOpt, defList);
|
||||
|
||||
|
||||
/*
|
||||
* All we need do here is update the pg_class row; the new options will be
|
||||
* propagated into relcaches during post-commit cache inval.
|
||||
|
||||
@ -2635,7 +2635,7 @@ void ForbidUserToSetCompressedOptions(List *options)
|
||||
if (FindInvalidOption(options, unSupportOptions, lengthof(unSupportOptions), &firstInvalidOpt)) {
|
||||
ereport(ERROR,
|
||||
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
|
||||
(errmsg("Un-support feature"), errdetail("Option \"%s\" doesn't allow ALTER on uncompressed table",
|
||||
(errmsg("Un-support feature"), errdetail("Option \"%s\" doesn't allow ALTER",
|
||||
unSupportOptions[firstInvalidOpt]))));
|
||||
}
|
||||
}
|
||||
|
||||
@ -41,10 +41,10 @@
|
||||
constexpr uint32 COMPRESS_ADDRESS_FLUSH_CHUNKS = 5000;
|
||||
|
||||
#define SUPPORT_COMPRESSED(relKind, relam) \
|
||||
((relKind) == RELKIND_RELATION || ((relKind) == RELKIND_INDEX && (relam) == BTREE_AM_OID))
|
||||
#define REL_SUPPORT_COMPRESSED(relation) \
|
||||
(((relation)->rd_rel->relkind) == RELKIND_RELATION || \
|
||||
(((relation)->rd_rel->relkind) == RELKIND_INDEX && ((relation)->rd_rel->relam) == BTREE_AM_OID))
|
||||
((relKind) == RELKIND_RELATION || \
|
||||
(((relKind) == RELKIND_INDEX || (relKind == RELKIND_GLOBAL_INDEX)) && (relam) == BTREE_AM_OID))
|
||||
|
||||
#define REL_SUPPORT_COMPRESSED(relation) SUPPORT_COMPRESSED((relation)->rd_rel->relkind, (relation)->rd_rel->relam)
|
||||
|
||||
typedef uint32 pc_chunk_number_t;
|
||||
const uint32 PAGE_COMPRESSION_VERSION = 92603;
|
||||
|
||||
@ -1,46 +1,46 @@
|
||||
create schema unspported_feature;
|
||||
create schema unsupported_feature;
|
||||
-- unspport compressType: 3
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(compresstype=3, compress_chunk_size=1024);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(compresstype=3, compress_chunk_size=1024);
|
||||
ERROR: value 3 out of bounds for option "compresstype"
|
||||
DETAIL: Valid values are between "0" and "2".
|
||||
-- unspport compress_chunk_size: 2000
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(compresstype=2, compress_chunk_size=2000);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(compresstype=2, compress_chunk_size=2000);
|
||||
ERROR: invalid compress_chunk_size 2000 , must be one of 512, 1024, 2048 or 4096 for compressed_table_1024
|
||||
-- unspport compress_prealloc_chunks: -1
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(compresstype=2, compress_prealloc_chunks=-1);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(compresstype=2, compress_prealloc_chunks=-1);
|
||||
ERROR: value -1 out of bounds for option "compress_prealloc_chunks"
|
||||
DETAIL: Valid values are between "0" and "7".
|
||||
-- unspport compress_prealloc_chunks: 8
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(compresstype=2, compress_prealloc_chunks=8);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(compresstype=2, compress_prealloc_chunks=8);
|
||||
ERROR: value 8 out of bounds for option "compress_prealloc_chunks"
|
||||
DETAIL: Valid values are between "0" and "7".
|
||||
-- unspport compress_level: 128
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(compresstype=2, compress_level=128);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(compresstype=2, compress_level=128);
|
||||
ERROR: value 128 out of bounds for option "compress_level"
|
||||
DETAIL: Valid values are between "-31" and "31".
|
||||
-- compresstype cant be used with column table
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(ORIENTATION = 'column', compresstype=2);
|
||||
ERROR: only row orientation table support compresstype.
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(ORIENTATION = 'column', compresstype=2);
|
||||
ERROR: compresstype can not be used in ustore table, segment table, column table, view, unlogged table or temp table.
|
||||
-- compresstype cant be used with temp table
|
||||
CREATE TEMP TABLE compressed_temp_table_1024(id int) WITH(compresstype=2);
|
||||
ERROR: only row orientation table support compresstype.
|
||||
ERROR: compresstype can not be used in ustore table, segment table, column table, view, unlogged table or temp table.
|
||||
-- compresstype cant be used with unlogged table
|
||||
CREATE unlogged TABLE compressed_unlogged_table_1024(id int) WITH(compresstype=2);
|
||||
ERROR: only row orientation table support compresstype.
|
||||
ERROR: compresstype can not be used in ustore table, segment table, column table, view, unlogged table or temp table.
|
||||
-- use compress_prealloc_chunks\compress_chunk_size\compress_level without compresstype
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(compress_prealloc_chunks=5);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(compress_prealloc_chunks=5);
|
||||
ERROR: compress_chunk_size/compress_prealloc_chunks/compress_level/compress_byte_convert/compress_diff_convert should be used with compresstype.
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(compress_chunk_size=1024);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(compress_chunk_size=1024);
|
||||
ERROR: compress_chunk_size/compress_prealloc_chunks/compress_level/compress_byte_convert/compress_diff_convert should be used with compresstype.
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(compress_byte_convert=true);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(compress_byte_convert=true);
|
||||
ERROR: compress_chunk_size/compress_prealloc_chunks/compress_level/compress_byte_convert/compress_diff_convert should be used with compresstype.
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(compress_diff_convert=true);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(compress_diff_convert=true);
|
||||
ERROR: compress_chunk_size/compress_prealloc_chunks/compress_level/compress_byte_convert/compress_diff_convert should be used with compresstype.
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(compress_level=5);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(compress_level=5);
|
||||
ERROR: compress_chunk_size/compress_prealloc_chunks/compress_level/compress_byte_convert/compress_diff_convert should be used with compresstype.
|
||||
-- unspport exchange
|
||||
CREATE TABLE unspported_feature.exchange_table(id int) WITH(compresstype=2);
|
||||
CREATE TABLE unspported_feature.alter_table(id int) partition by range(id)
|
||||
CREATE TABLE unsupported_feature.exchange_table(id int) WITH(compresstype=2);
|
||||
CREATE TABLE unsupported_feature.alter_table(id int) partition by range(id)
|
||||
(
|
||||
partition p0 values less than(5000),
|
||||
partition p1 values less than(10000),
|
||||
@ -51,46 +51,65 @@ CREATE TABLE unspported_feature.alter_table(id int) partition by range(id)
|
||||
partition p6 values less than(60000),
|
||||
partition p7 values less than(70000)
|
||||
);
|
||||
ALTER TABLE unspported_feature.alter_table EXCHANGE PARTITION FOR(2500) WITH TABLE unspported_feature.exchange_table;
|
||||
ALTER TABLE unsupported_feature.alter_table EXCHANGE PARTITION FOR(2500) WITH TABLE unsupported_feature.exchange_table;
|
||||
ERROR: tables in ALTER TABLE EXCHANGE PARTITION must have the same type of compress
|
||||
-- unspport alter compress_chunk_size
|
||||
create TABLE unspported_feature.alter_table_option(id int) WITH(compresstype=2);
|
||||
\d+ unspported_feature.alter_table_option
|
||||
Table "unspported_feature.alter_table_option"
|
||||
create TABLE unsupported_feature.alter_table_option(id int) WITH(compresstype=2);
|
||||
\d+ unsupported_feature.alter_table_option
|
||||
Table "unsupported_feature.alter_table_option"
|
||||
Column | Type | Modifiers | Storage | Stats target | Description
|
||||
--------+---------+-----------+---------+--------------+-------------
|
||||
id | integer | | plain | |
|
||||
Has OIDs: no
|
||||
Options: orientation=row, compresstype=2
|
||||
|
||||
ALTER TABLE unspported_feature.alter_table_option SET(compresstype=0); -- fail
|
||||
ALTER TABLE unsupported_feature.alter_table_option SET(compresstype=0); -- fail
|
||||
ERROR: change compresstype OPTION is not supported
|
||||
ALTER TABLE unspported_feature.alter_table_option SET(compress_chunk_size=2048); -- fail
|
||||
ALTER TABLE unsupported_feature.alter_table_option SET(compress_chunk_size=2048); -- fail
|
||||
ERROR: change compress_chunk_size OPTION is not supported
|
||||
ALTER TABLE unspported_feature.alter_table_option SET(compress_level=2, compress_prealloc_chunks=0);
|
||||
ALTER TABLE unsupported_feature.alter_table_option SET(compress_level=2, compress_prealloc_chunks=0);
|
||||
-- alter compress_byte_convert\compress_diff_convert
|
||||
create table unspported_feature.rolcompress_table_001(a int) with (compresstype=2, compress_diff_convert=true); -- fail
|
||||
create table unsupported_feature.rolcompress_table_001(a int) with (compresstype=2, compress_diff_convert=true); -- fail
|
||||
ERROR: compress_diff_convert should be used with compress_byte_convert.
|
||||
create table unspported_feature.t_rowcompress_0007(cid int, name varchar2) with (compresstype=1);
|
||||
alter table unspported_feature.t_rowcompress_0007 set (compress_diff_convert=true); --fail
|
||||
create table unsupported_feature.t_rowcompress_0007(cid int, name varchar2) with (compresstype=1);
|
||||
alter table unsupported_feature.t_rowcompress_0007 set (compress_diff_convert=true); --fail
|
||||
ERROR: compress_diff_convert should be used with compress_byte_convert.
|
||||
alter table unspported_feature.t_rowcompress_0007 set (compress_byte_convert=true, compress_diff_convert=true); --success
|
||||
alter table unspported_feature.t_rowcompress_0007 set (compress_level=31); --failed
|
||||
alter table unsupported_feature.t_rowcompress_0007 set (compress_byte_convert=true, compress_diff_convert=true); --success
|
||||
alter table unsupported_feature.t_rowcompress_0007 set (compress_level=31); --failed
|
||||
ERROR: compress_level should be used with ZSTD algorithm.
|
||||
create table unspported_feature.t_rowcompress_pglz_compresslevel(id int) with (compresstype=1,compress_level=2); -- failed
|
||||
create table unsupported_feature.t_rowcompress_pglz_compresslevel(id int) with (compresstype=1,compress_level=2); -- failed
|
||||
ERROR: compress_level should be used with ZSTD algorithm.
|
||||
create table unspported_feature.t_rowcompress_pglz_compresslevel(id int) with (compresstype=2,compress_level=2); -- success
|
||||
CREATE TABLE unspported_feature.index_test(id int, c1 text);
|
||||
create table unsupported_feature.t_rowcompress_pglz_compresslevel(id int) with (compresstype=2,compress_level=2); -- success
|
||||
CREATE TABLE unsupported_feature.index_test(id int, c1 text);
|
||||
-- ustore
|
||||
CREATE TABLE unspported_feature.ustore_table(id int, c1 text) WITH(compresstype=2, storage_type=ustore); --failed
|
||||
ERROR: only row orientation table support compresstype.
|
||||
CREATE INDEX tbl_pc_idx1 on unspported_feature.index_test(c1) WITH(compresstype=2, storage_type=ustore); --failed
|
||||
CREATE TABLE unsupported_feature.ustore_table(id int, c1 text) WITH(compresstype=2, storage_type=ustore); --failed
|
||||
ERROR: compresstype can not be used in ustore table, segment table, column table, view, unlogged table or temp table.
|
||||
CREATE INDEX tbl_pc_idx1 on unsupported_feature.index_test(c1) WITH(compresstype=2, storage_type=ustore); --failed
|
||||
ERROR: Can not use compress option in ustore index.
|
||||
-- segment
|
||||
CREATE TABLE unspported_feature.segment_table(id int, c1 text) WITH(compresstype=2, segment=on); --failed
|
||||
ERROR: only row orientation table support compresstype.
|
||||
CREATE INDEX on unspported_feature.index_test(c1) WITH(compresstype=2, segment=on); --failed
|
||||
CREATE TABLE unsupported_feature.segment_table(id int, c1 text) WITH(compresstype=2, segment=on); --failed
|
||||
ERROR: compresstype can not be used in ustore table, segment table, column table, view, unlogged table or temp table.
|
||||
CREATE INDEX on unsupported_feature.index_test(c1) WITH(compresstype=2, segment=on); --failed
|
||||
ERROR: Can not use compress option in segment storage.
|
||||
-- set compress_diff_convert
|
||||
create table unspported_feature.compress_byte_test(id int) with (compresstype=2, compress_byte_convert=false, compress_diff_convert = true); -- failed
|
||||
create table unsupported_feature.compress_byte_test(id int) with (compresstype=2, compress_byte_convert=false, compress_diff_convert = true); -- failed
|
||||
ERROR: compress_diff_convert should be used with compress_byte_convert.
|
||||
create table unsupported_feature.test(id int) with (compresstype=2); -- success
|
||||
alter table unsupported_feature.test set(Compresstype=1); -- failed
|
||||
ERROR: change compresstype OPTION is not supported
|
||||
alter table unsupported_feature.test set(Compress_level=3); -- success
|
||||
create table lm_rcp_4 (c1 int,c2 varchar2,c3 number,c4 money,c5 CHAR(20),c6 CLOB,c7 blob,c8 DATE,c9 BOOLEAN,c10 TIMESTAMP,c11 point,columns12 cidr) with(Compresstype=2,Compress_chunk_size=512)
|
||||
partition by list(c1) subpartition by range(c3)(
|
||||
partition ts1 values(1,2,3,4,5)(subpartition ts11 values less than(500),subpartition ts12 values less than(5000),subpartition ts13 values less than(MAXVALUE)),
|
||||
partition ts2 values(6,7,8,9,10),
|
||||
partition ts3 values(11,12,13,14,15)(subpartition ts31 values less than(5000),subpartition ts32 values less than(10000),subpartition ts33 values less than(MAXVALUE)),
|
||||
partition ts4 values(default));
|
||||
create unique index indexg_lm_rcp_4 on lm_rcp_4(c1 NULLS first,c2,c3) global
|
||||
with(FILLFACTOR=80,Compresstype=2,Compress_chunk_size=512,compress_byte_convert=1,compress_diff_convert=1);
|
||||
--s3.
|
||||
alter index indexg_lm_rcp_4 rename to indexg_lm_rcp_4_newname;
|
||||
--s4.修改压缩类型
|
||||
alter index indexg_lm_rcp_4_newname set(Compresstype=1);
|
||||
ERROR: change compresstype OPTION is not supported
|
||||
--s5.修改Compress_level
|
||||
alter index indexg_lm_rcp_4_newname set(Compress_level=3);
|
||||
|
||||
@ -1,29 +1,29 @@
|
||||
create schema unspported_feature;
|
||||
create schema unsupported_feature;
|
||||
-- unspport compressType: 3
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(compresstype=3, compress_chunk_size=1024);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(compresstype=3, compress_chunk_size=1024);
|
||||
-- unspport compress_chunk_size: 2000
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(compresstype=2, compress_chunk_size=2000);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(compresstype=2, compress_chunk_size=2000);
|
||||
-- unspport compress_prealloc_chunks: -1
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(compresstype=2, compress_prealloc_chunks=-1);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(compresstype=2, compress_prealloc_chunks=-1);
|
||||
-- unspport compress_prealloc_chunks: 8
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(compresstype=2, compress_prealloc_chunks=8);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(compresstype=2, compress_prealloc_chunks=8);
|
||||
-- unspport compress_level: 128
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(compresstype=2, compress_level=128);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(compresstype=2, compress_level=128);
|
||||
-- compresstype cant be used with column table
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(ORIENTATION = 'column', compresstype=2);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(ORIENTATION = 'column', compresstype=2);
|
||||
-- compresstype cant be used with temp table
|
||||
CREATE TEMP TABLE compressed_temp_table_1024(id int) WITH(compresstype=2);
|
||||
-- compresstype cant be used with unlogged table
|
||||
CREATE unlogged TABLE compressed_unlogged_table_1024(id int) WITH(compresstype=2);
|
||||
-- use compress_prealloc_chunks\compress_chunk_size\compress_level without compresstype
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(compress_prealloc_chunks=5);
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(compress_chunk_size=1024);
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(compress_byte_convert=true);
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(compress_diff_convert=true);
|
||||
CREATE TABLE unspported_feature.compressed_table_1024(id int) WITH(compress_level=5);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(compress_prealloc_chunks=5);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(compress_chunk_size=1024);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(compress_byte_convert=true);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(compress_diff_convert=true);
|
||||
CREATE TABLE unsupported_feature.compressed_table_1024(id int) WITH(compress_level=5);
|
||||
-- unspport exchange
|
||||
CREATE TABLE unspported_feature.exchange_table(id int) WITH(compresstype=2);
|
||||
CREATE TABLE unspported_feature.alter_table(id int) partition by range(id)
|
||||
CREATE TABLE unsupported_feature.exchange_table(id int) WITH(compresstype=2);
|
||||
CREATE TABLE unsupported_feature.alter_table(id int) partition by range(id)
|
||||
(
|
||||
partition p0 values less than(5000),
|
||||
partition p1 values less than(10000),
|
||||
@ -34,29 +34,48 @@ CREATE TABLE unspported_feature.alter_table(id int) partition by range(id)
|
||||
partition p6 values less than(60000),
|
||||
partition p7 values less than(70000)
|
||||
);
|
||||
ALTER TABLE unspported_feature.alter_table EXCHANGE PARTITION FOR(2500) WITH TABLE unspported_feature.exchange_table;
|
||||
ALTER TABLE unsupported_feature.alter_table EXCHANGE PARTITION FOR(2500) WITH TABLE unsupported_feature.exchange_table;
|
||||
-- unspport alter compress_chunk_size
|
||||
create TABLE unspported_feature.alter_table_option(id int) WITH(compresstype=2);
|
||||
\d+ unspported_feature.alter_table_option
|
||||
ALTER TABLE unspported_feature.alter_table_option SET(compresstype=0); -- fail
|
||||
ALTER TABLE unspported_feature.alter_table_option SET(compress_chunk_size=2048); -- fail
|
||||
ALTER TABLE unspported_feature.alter_table_option SET(compress_level=2, compress_prealloc_chunks=0);
|
||||
create TABLE unsupported_feature.alter_table_option(id int) WITH(compresstype=2);
|
||||
\d+ unsupported_feature.alter_table_option
|
||||
ALTER TABLE unsupported_feature.alter_table_option SET(compresstype=0); -- fail
|
||||
ALTER TABLE unsupported_feature.alter_table_option SET(compress_chunk_size=2048); -- fail
|
||||
ALTER TABLE unsupported_feature.alter_table_option SET(compress_level=2, compress_prealloc_chunks=0);
|
||||
-- alter compress_byte_convert\compress_diff_convert
|
||||
create table unspported_feature.rolcompress_table_001(a int) with (compresstype=2, compress_diff_convert=true); -- fail
|
||||
create table unsupported_feature.rolcompress_table_001(a int) with (compresstype=2, compress_diff_convert=true); -- fail
|
||||
|
||||
create table unspported_feature.t_rowcompress_0007(cid int, name varchar2) with (compresstype=1);
|
||||
alter table unspported_feature.t_rowcompress_0007 set (compress_diff_convert=true); --fail
|
||||
alter table unspported_feature.t_rowcompress_0007 set (compress_byte_convert=true, compress_diff_convert=true); --success
|
||||
alter table unspported_feature.t_rowcompress_0007 set (compress_level=31); --failed
|
||||
create table unspported_feature.t_rowcompress_pglz_compresslevel(id int) with (compresstype=1,compress_level=2); -- failed
|
||||
create table unspported_feature.t_rowcompress_pglz_compresslevel(id int) with (compresstype=2,compress_level=2); -- success
|
||||
create table unsupported_feature.t_rowcompress_0007(cid int, name varchar2) with (compresstype=1);
|
||||
alter table unsupported_feature.t_rowcompress_0007 set (compress_diff_convert=true); --fail
|
||||
alter table unsupported_feature.t_rowcompress_0007 set (compress_byte_convert=true, compress_diff_convert=true); --success
|
||||
alter table unsupported_feature.t_rowcompress_0007 set (compress_level=31); --failed
|
||||
create table unsupported_feature.t_rowcompress_pglz_compresslevel(id int) with (compresstype=1,compress_level=2); -- failed
|
||||
create table unsupported_feature.t_rowcompress_pglz_compresslevel(id int) with (compresstype=2,compress_level=2); -- success
|
||||
|
||||
CREATE TABLE unspported_feature.index_test(id int, c1 text);
|
||||
CREATE TABLE unsupported_feature.index_test(id int, c1 text);
|
||||
-- ustore
|
||||
CREATE TABLE unspported_feature.ustore_table(id int, c1 text) WITH(compresstype=2, storage_type=ustore); --failed
|
||||
CREATE INDEX tbl_pc_idx1 on unspported_feature.index_test(c1) WITH(compresstype=2, storage_type=ustore); --failed
|
||||
CREATE TABLE unsupported_feature.ustore_table(id int, c1 text) WITH(compresstype=2, storage_type=ustore); --failed
|
||||
CREATE INDEX tbl_pc_idx1 on unsupported_feature.index_test(c1) WITH(compresstype=2, storage_type=ustore); --failed
|
||||
-- segment
|
||||
CREATE TABLE unspported_feature.segment_table(id int, c1 text) WITH(compresstype=2, segment=on); --failed
|
||||
CREATE INDEX on unspported_feature.index_test(c1) WITH(compresstype=2, segment=on); --failed
|
||||
CREATE TABLE unsupported_feature.segment_table(id int, c1 text) WITH(compresstype=2, segment=on); --failed
|
||||
CREATE INDEX on unsupported_feature.index_test(c1) WITH(compresstype=2, segment=on); --failed
|
||||
-- set compress_diff_convert
|
||||
create table unspported_feature.compress_byte_test(id int) with (compresstype=2, compress_byte_convert=false, compress_diff_convert = true); -- failed
|
||||
create table unsupported_feature.compress_byte_test(id int) with (compresstype=2, compress_byte_convert=false, compress_diff_convert = true); -- failed
|
||||
|
||||
create table unsupported_feature.test(id int) with (compresstype=2); -- success
|
||||
alter table unsupported_feature.test set(Compresstype=1); -- failed
|
||||
alter table unsupported_feature.test set(Compress_level=3); -- success
|
||||
|
||||
create table lm_rcp_4 (c1 int,c2 varchar2,c3 number,c4 money,c5 CHAR(20),c6 CLOB,c7 blob,c8 DATE,c9 BOOLEAN,c10 TIMESTAMP,c11 point,columns12 cidr) with(Compresstype=2,Compress_chunk_size=512)
|
||||
partition by list(c1) subpartition by range(c3)(
|
||||
partition ts1 values(1,2,3,4,5)(subpartition ts11 values less than(500),subpartition ts12 values less than(5000),subpartition ts13 values less than(MAXVALUE)),
|
||||
partition ts2 values(6,7,8,9,10),
|
||||
partition ts3 values(11,12,13,14,15)(subpartition ts31 values less than(5000),subpartition ts32 values less than(10000),subpartition ts33 values less than(MAXVALUE)),
|
||||
partition ts4 values(default));
|
||||
create unique index indexg_lm_rcp_4 on lm_rcp_4(c1 NULLS first,c2,c3) global
|
||||
with(FILLFACTOR=80,Compresstype=2,Compress_chunk_size=512,compress_byte_convert=1,compress_diff_convert=1);
|
||||
--s3.
|
||||
alter index indexg_lm_rcp_4 rename to indexg_lm_rcp_4_newname;
|
||||
--s4.修改压缩类型
|
||||
alter index indexg_lm_rcp_4_newname set(Compresstype=1);
|
||||
--s5.修改Compress_level
|
||||
alter index indexg_lm_rcp_4_newname set(Compress_level=3);
|
||||
Reference in New Issue
Block a user