OpenMLDB icon indicating copy to clipboard operation
OpenMLDB copied to clipboard

When partitionnum = 0 and distribution is not specified, the creation of the table should fail

Open wuyou10206 opened this issue 3 years ago • 1 comments

Bug Description When partitionnum = 0 and distribution is not specified, the creation of the table should fail, but now it succeeds

create table t4 (c1 string NOT NULL,c2 int,c3 timestamp,c4 timestamp,index(key=(c1),ts=c4,ttl=0m))
options (
partitionnum = 0,
replicanum = 3
);

Expected Behavior An error message should be prompted

Steps to Reproduce

wuyou10206 avatar Jul 21 '22 11:07 wuyou10206

The following SQL will prompt that the table cannot be created. It is expected that it can be created and partitionnum=1

create table t5 (c1 string NOT NULL,c2 int,c3 timestamp,c4 timestamp,index(key=(c1),ts=c4,ttl=0m))
options (
partitionnum = 0,
replicanum = 3,
distribution = [ ('172.24.4.55:30014', [ '172.24.4.55:30015','172.24.4.55:30022' ])]
);

wuyou10206 avatar Jul 28 '22 04:07 wuyou10206