mirror of
https://github.com/GreptimeTeam/greptimedb.git
synced 2026-01-06 21:32:58 +00:00
* [WIP]:delete sql * [fix]:time parser bug * [fix]:resolve conflict * [fmt]:cargo fmt * [fix]:remove unless log * [fix]:test * [feat]:add error parse * [fix]:resolve conflict * [fix]:remove unless code * [fix]:remove unless code * [test]:add IT * [fix]:add license * [fix]:ci * [fix]:ci * [fix]:ci * [fix]:remove * [fix]:ci * [feat]:add sql * [fix]:modify sql * [feat]:refactor parser_expr * [feat]:rm backtrace * [fix]:ci * [fix]: conversation * [fix]: conversation * feat:refactor delete * feat:refactor delete * fix:resolve conversation * fix:ut * fix:ut * fix:conversation * fix:conversation * fix:conservation --------- Co-authored-by: xieqijun <qijun@apache.org>
29 lines
1.1 KiB
Plaintext
29 lines
1.1 KiB
Plaintext
CREATE TABLE monitor ( host STRING, ts TIMESTAMP, cpu DOUBLE DEFAULT 0, memory DOUBLE, TIME INDEX (ts), PRIMARY KEY(host)) ;
|
|
|
|
Affected Rows: 0
|
|
|
|
insert into monitor(host, cpu, memory, ts) values ('host1', 66.6, 1024, 1655276557000), ('host2', 77.7, 2048, 1655276558000), ('host3', 88.8, 3072, 1655276559000);
|
|
|
|
Affected Rows: 3
|
|
|
|
delete from monitor where cpu = 66.6 and ts = 1655276557000;
|
|
|
|
Error: 1004(InvalidArguments), Missing column host in write batch
|
|
|
|
delete from monitor where host = 'host1' or ts = 1655276557000;
|
|
|
|
Error: 1004(InvalidArguments), Not support SQL, error: Not support sql expr:host = 'host1' OR ts = 1655276557000,correct format is tagkey1 = tagvalue1 and ts = value
|
|
|
|
delete from monitor where host = 'host1' or ts != 1655276557000;
|
|
|
|
Error: 1004(InvalidArguments), Not support SQL, error: Not support sql expr:host = 'host1' OR ts <> 1655276557000,correct format is tagkey1 = tagvalue1 and ts = value
|
|
|
|
delete from monitor where ts != 1655276557000;
|
|
|
|
Error: 1004(InvalidArguments), Not support SQL, error: Not support sql expr:ts <> 1655276557000,correct format is tagkey1 = tagvalue1 and ts = value
|
|
|
|
drop table monitor;
|
|
|
|
Affected Rows: 1
|
|
|