Commit Graph

350 Commits

Author SHA1 Message Date
shenglian zhou b8205f23bf enhance: ip whitelist before debug 2023-08-30 14:32:46 +08:00
yihaoDeng 89bb80db65 fix create tag error 2023-08-30 10:46:28 +08:00
slzhou f280da26da Merge branch '3.0' of github.com:taosdata/TDengine into szhou/ip-whitelist 2023-08-29 14:16:37 +08:00
dapan1121 1f40da6fef Merge remote-tracking branch 'origin/main' into 3.0 2023-08-28 09:28:55 +08:00
slzhou d5db4b16ba Merge branch '3.0' of github.com:taosdata/TDengine into szhou/tags-after-distinct 2023-08-24 16:57:25 +08:00
Haojun Liao 3c6870275b fix(parser): update the key words for disk io throttling. 2023-08-24 16:45:47 +08:00
slzhou b16470414a enhance: ip range white list to user 2023-08-24 15:54:10 +08:00
slzhou f6dbd0b0e4 fix: select distinct/all tags instead of select tags distinct 2023-08-24 14:03:40 +08:00
wangjiaming0909 366a9cc009 Revert "feat: support column comment"
This reverts commit dcbef83dea.
2023-08-24 13:54:27 +08:00
wangjiaming0909 c2af41d0d0 Revert "feat: support alter table add column with comment"
This reverts commit cb027cc5c5.
2023-08-24 13:48:35 +08:00
dapan1121 efc5589aa2 Merge remote-tracking branch 'origin/3.0' into feat/TD-24700 2023-08-18 14:11:26 +08:00
slzhou 4e2a26e8be Merge branch '3.0' of github.com:taosdata/TDengine into szhou/select-tags-scan 2023-08-18 08:46:17 +08:00
slzhou 85d1dbe00a Merge branch '3.0' of github.com:taosdata/TDengine into szhou/select-tags-scan 2023-08-17 16:27:37 +08:00
dapan1121 1b038d2dcd Merge remote-tracking branch 'origin/3.0' into feat/TD-24700 2023-08-17 16:08:39 +08:00
Benguang Zhao 7735e6f388 Merge branch 3.0 to FEAT/TD-25699-3.0 2023-08-17 16:04:23 +08:00
Benguang Zhao 80518cf82b feat: support sql command show vnodes for all dnodes 2023-08-16 20:17:11 +08:00
dapan1121 91d6734b34 fix: join condition push down issue 2023-08-16 14:28:39 +08:00
Benguang Zhao 8b26ea7a55 enh: add command show vnodes on dnode <dnode_id> 2023-08-16 13:31:52 +08:00
wangjiaming0909 cb027cc5c5 feat: support alter table add column with comment 2023-08-16 11:07:40 +08:00
wangjiaming0909 dcbef83dea feat: support column comment 2023-08-15 16:30:02 +08:00
slzhou 514da6e1b0 fix: select tags and set tag scan execution mode 2023-08-15 15:16:57 +08:00
shenglian zhou 9fb9d863b9 enhance: modify sql.y 2023-08-15 11:29:17 +08:00
dapan1121 31b0bcd716 fix: taosd crash issue 2023-08-15 08:51:23 +08:00
dapan1121 6a78053b51 feat: add hint supporting 2023-08-14 17:21:15 +08:00
dapan1121 ae0426717a feat: add hint option 2023-08-14 10:47:56 +08:00
dapan1121 b4b9a12d61 fix: memory issue 2023-08-14 09:06:21 +08:00
dapan1121 c9656d3f77 fix: fix memory issues 2023-08-11 17:39:41 +08:00
Ganlin Zhao b058f3c881 add syntax for show tags/index/table tags from db.tb 2023-07-12 13:50:17 +08:00
Ganlin Zhao 5ec94c0697 add syntax for show tags/index/table tags from db.tb 2023-07-12 11:06:47 +08:00
wangmm0220 20e616d59d feat:parse sql.y 2023-06-30 19:36:39 +08:00
wangmm0220 af16b62289 fix:modify sql.y 2023-06-30 16:57:29 +08:00
wangmm0220 58c7011e0e feat:support only meta in tmq subscriptions 2023-06-30 11:42:40 +08:00
Ganlin Zhao e8eadeb9f5 Merge branch '3.0' into feat/TS-3048 2023-06-06 14:55:12 +08:00
Ganlin Zhao 57c301553b feat(query): support single point interp syntax 2023-05-29 16:40:30 +08:00
wangmm0220 78db3520a6 fix:conflict 2023-05-29 14:57:03 +08:00
Dingle Zhang 984211f3b4
Feature/3.0 geometry (#21037)
* Add GEOMETRY data type and make sql.c able to parse it. The GEMETRY works like BINARY so far.

* add GEOMETRY type into gConvertTypes to fix some issues like DELETE calling

* change some test cases to make sure no same timestamp is inserted, and add my smoketest.sh

* Add a function MakePoint() and introduce a lib geometry

* implement sql functions GeomFromText() and AsText()

* Use GEOS *_r funcions instead for thread safety

* Handle with TSDB_DATA_TYPE_GEOMETRY when INSERT geometry data by converting WKT.
Add geosWrapper to wrap the basic GEOS functions for TDEngine.

* refactor AsText and MakePoint functions to be like GeomFromText

* Show WKT when print geometry data in screen
Dump hex data when dump geometry data in a file

* define TYPE_BYTES item for TSDB_DATA_TYPE_GEOMETRY, which casued some strange issues.

* set number of decimals of WKT to 6

* Implement SQL function Intersects()

* refactor geometry sql functions

* Add geosErrMsgeHandler() to get the GEOS error detail

* use threadlocal to instantiate SGeosContext
call destroyGeosContext() only if the thread exists

* remove SGeosContext *context param for all geometry functions since we use thread local one,
so that all caller do not need to know the context.

* Modify Intersects() to call PreparedIntersects() when one of param is a constant, which has higher performance.

* rename prepareFn() to initCtxFn() to avoid confusion with PreparedFn

* Add prefix "ST_" for all geometry functions

* move getThreadLocalGeosCtx() and destroyThreadLocalGeosCtx() into util,
so that all unit test tools can compile

* Add unit test for geometry lib, only test MakePoint so far

* refactor and enhance existing cases in geomFuncTest

* implement NULL type and NULL value test for geomFuncTest

* add test on geomFromText()

* add unit test on AsText() in geomFuncTest

* combine some makePointFunction test items

* add intersectsFunctionTwoColumns test
refactor on callGeomFromTextWrapper functions

* enhance intersectsFunction test to add cases like input constant , NULL type, NULL value, or wrong content

* add more cases into intersectsFunction test

* Add basic test on geometry in system test

* Add ST_GeomFromText and ST_AsText function test in system test on geometry

* add ST_Intersects function test in system test on geometry

* support to check expectedErrno in system test on geometry

* adjust geomTest unit test and geometry system test

* add geometry data type and functions in doc english version

* implement touchesFunction() in geometry lib
refactor geometry relation functions model

* separate gemFuncTest into several src files

* add unit test on touchesFunction

* support sql function ST_Touches()
add system test on ST_Touches

* add docs for ST_Touches()

* Add ST_Contains()

* Add ST_Covers()

* Add ST_Equals()

* add swapAllowed param for geomRelationFunction()
read geom2 earlier intead of at doGeosRelation()

* Add ST_ContainsProperly()

* build on windows

* Merge from 3.0 to 3.0_geometry

* change macro definition TSDB_DATA_TYPE_GEOMETRY as the last one for compatibility

* change '\\NULL' to 'NULL' back in shellDumpFieldToFile()

* add /usr/local/include into include directory

* add /usr/local/inlcude and /usr/local/lib in cmake.platform for DARWIN
2023-05-24 15:36:46 +08:00
wangmm0220 8c1c2a2f97 fix:add grammar support 2023-05-23 17:47:17 +08:00
dapan1121 cf7b4593e7 feat: add drop dnode unsafe command 2023-05-16 09:50:10 +08:00
Haojun Liao 99148d6719 other: merge 3.0 2023-05-13 20:02:48 +08:00
dapan1121 a8c65cd25a feat: support restore dnode clause 2023-05-09 19:19:14 +08:00
Xiaoyu Wang dc5235eb92 feat: add pause/resume stream statement 2023-04-24 14:48:33 +08:00
yihaoDeng 917b07348c Merge branch 'fix/rocksdbState' into enh/rocksRevert 2023-04-23 02:37:26 +00:00
dapan1121 3c2fc48e74 feat: support new table_prefix/table_suffix mode 2023-04-21 14:17:07 +08:00
Xiaoyu Wang 1d2764ebdb feat: the fill value clause supports constant expressions 2023-04-18 15:36:50 +08:00
Xiaoyu Wang 4c04b155d5 merge main 2023-04-11 15:56:28 +08:00
Xiaoyu Wang e2f82f4423 merge main 2023-04-10 09:56:03 +08:00
Xiaoyu Wang 9b2a94f281 fix: column comment is not supported 2023-04-04 18:04:10 +08:00
Xiaoyu Wang cc7485812a feat: add 'or replace' clause to 'create function' statement 2023-04-04 17:45:18 +08:00
Xiaoyu Wang daaf4871ac feat: table level privilege syntax 2023-03-28 18:43:58 +08:00
Xiaoyu Wang eb79046a70 merge 3.0 2023-03-22 11:42:02 +08:00
Xiaoyu Wang fbc9b2404e feat: add sql command 'balance vgroup leader' 2023-03-22 09:53:56 +08:00
Xiaoyu Wang 58ebd3539d feat: alter database wal_retention_period/wal_retention_size 2023-03-21 16:45:19 +08:00
Xiaoyu Wang a846c26ef9 merge main 2023-03-11 16:14:27 +08:00
Xiaoyu Wang e5de317f44 feat: alter database stt_trigger/minrows 2023-03-09 16:04:38 +08:00
Xiaoyu Wang 4c8bab7e58 merge main 2023-03-08 10:59:33 +08:00
Xiaoyu Wang df0d200f59 feat: the compact command adds 'start with end with' clause 2023-03-07 15:24:04 +08:00
Xiaoyu Wang 599967d39f feat: add language clause for create function 2023-03-04 11:08:50 +08:00
Xiaoyu Wang e937c77275 fix: create stream syntax check 2023-03-03 18:35:51 +08:00
Xiaoyu Wang 9305b0efd0 fix: create stream syntax check 2023-03-03 16:57:13 +08:00
Xiaoyu Wang 618c934fb2 enh: drop tables syntax optimization 2023-02-22 15:16:16 +08:00
Xiaoyu Wang c597de099f merge main 2023-02-20 13:41:27 +08:00
Xiaoyu Wang 3382a24a69 merge main 2023-02-10 18:03:11 +08:00
Xiaoyu Wang b2e60da1cf merge main 2023-02-10 10:34:55 +08:00
Xiaoyu Wang fcff07675d merge main 2023-02-09 11:29:38 +08:00
Xiaoyu Wang 9bc225ffda merge 3.0 2023-02-09 09:44:29 +08:00
Xiaoyu Wang 09925437e3 merge main 2023-02-08 09:51:52 +08:00
Xiaoyu Wang a52371959e feat: add ignore update option for create stream 2023-02-07 19:31:08 +08:00
Xiaoyu Wang f2ff17dace merge 3.0 2023-02-06 14:18:13 +08:00
dapan1121 d5bc02c1e8 feat: support force fill 2023-02-02 18:03:30 +08:00
Xiaoyu Wang 4b4468e392 feat: explain insert select 2023-01-31 16:04:57 +08:00
Hongze Cheng 11bc53bbd7 Merge branch '3.0' of https://github.com/taosdata/TDengine into feat/vnode_compact 2023-01-31 14:07:58 +08:00
Xiaoyu Wang ca43c0ab55 feat: support writing streams to existing tables 2023-01-17 16:47:43 +08:00
Xiaoyu Wang ac09a05cfa feat: create stream support delete_mark option 2023-01-17 15:34:58 +08:00
Xiaoyu Wang 9df6f69371 merge 3.0 2023-01-04 15:02:31 +08:00
Xiaoyu Wang fdde287ca9 merge main 2023-01-04 11:43:20 +08:00
Alex Duan c0a16094ab fix: merge from 3.0 2022-12-30 19:02:48 +08:00
Xiaoyu Wang de418e8c8d feat: support writing streams to existing tables 2022-12-30 10:11:41 +08:00
Alex Duan 0c422345b3 feat: support show cluster alive; and show db.alive; 2022-12-29 18:07:57 +08:00
Xiaoyu Wang e0ca1affdf fix: escape error in create topic/stream 2022-12-29 14:39:02 +08:00
Hongze Cheng de6be90cb5 Merge branch '3.0' of https://github.com/taosdata/TDengine into feat/vnode_compact 2022-12-29 10:00:47 +08:00
Xiaoyu Wang b6aadbf16f sql command 'create index' 2022-12-28 10:31:34 +08:00
Xiaoyu Wang b52ebb6fd5 feat: sql command 'compact database' 2022-12-27 11:11:02 +08:00
Ganlin Zhao b1a1e49cb7 Merge branch '3.0' into feat/TS-2158 2022-12-19 17:03:34 +08:00
Xiaoyu Wang 4cfa6cea33 enh: tsma support first/last/count functions 2022-12-19 10:57:56 +08:00
Ganlin Zhao 09061bcc57 Merge branch '3.0' into feat/TS-2158 2022-12-19 09:23:32 +08:00
Xiaoyu Wang d3cb2a3a0a merge main 2022-12-18 20:36:06 +08:00
Ganlin Zhao 61cfca6eb9 feat(query): add _isfilled pseudocolumn to indicate data is origin
or filled.
2022-12-14 16:23:49 +08:00
Xiaoyu Wang 9929c4aa72 merge 3.0 2022-12-13 14:25:53 +08:00
Xiaoyu Wang b69725adaa enh: shielding database option 'strict' 2022-12-13 10:00:24 +08:00
Xiaoyu Wang dc64bb5110 enh: shielding sql command 'alter database strict' 2022-12-12 13:22:23 +08:00
Xiaoyu Wang bc36bc188e feat: event window 2022-12-08 09:36:37 +08:00
Xiaoyu Wang bc413b8fff feat: add stream option 'delete_mark' 2022-12-06 16:07:11 +08:00
Xiaoyu Wang 4e8acca2eb feat: sql command 'show user privileges' 2022-11-30 19:24:15 +08:00
Xiaoyu Wang f34e166f49 fix: select null error 2022-11-28 11:22:11 +08:00
Xiaoyu Wang 38f20ec32d enh: show table tags command extension 2022-11-10 17:22:13 +08:00
Xiaoyu Wang ae4354c277 enh: add sql command 'drop dnode id force' 2022-10-31 10:30:54 +08:00
Xiaoyu Wang 02ac6fa552 enh: add unit test and delete useless code 2022-10-26 17:01:55 +08:00
Xiaoyu Wang 0fdce91b5a fix: wrong permissions of 'show variables' command 2022-10-24 16:34:10 +08:00
Xiaoyu Wang 7c6ade9c07 enh: alter db replica 2022-10-20 17:02:57 +08:00
Xiaoyu Wang 947e9d6458 fix: some problems of parser 2022-10-12 10:16:29 +08:00
Xiaoyu Wang b00c4257e4 feat: 'alter database pages' and 'alter database buffer' 2022-10-08 15:24:18 +08:00
Xiaoyu Wang 73642ac3a2 feat: sql command 'show table tags from table_name' 2022-09-29 16:16:49 +08:00
Xiaoyu Wang 8caa36299c feat: add the _irowts pseudo column to output the timestamp of the interp 2022-09-27 15:23:24 +08:00
Xiaoyu Wang 1d62834e5c feat(stream): tag and child table name improvement 2022-09-26 18:39:47 +08:00
Xiaoyu Wang 50ebcb5006 feat: case when expression 2022-09-22 19:20:21 +08:00
Xiaoyu Wang cf759fba42 fix: parsing conflicts 2022-09-16 19:54:46 +08:00
Xiaoyu Wang 4ff42ad980 fix: parsing conflicts 2022-09-16 15:53:27 +08:00
Xiaoyu Wang 6cf578f299 feat: database option 'tsdb_pagesize' 2022-09-13 14:19:50 +08:00
Xiaoyu Wang ccaf6f8a78 feat: add database option 'table_prefix' and 'table_suffix' 2022-09-03 11:22:36 +08:00
Xiaoyu Wang 594e4b376e feat: sql command 'show vnodes' and database option 'sst_trigger' 2022-09-01 19:01:37 +08:00
Xiaoyu Wang d8fd0b89b1 fix: user permission error with sysinfo 0 2022-08-25 16:50:31 +08:00
Xiaoyu Wang 1cce6494a6 enh: create stream options adjust 2022-08-12 15:04:04 +08:00
Xiaoyu Wang 9a9aef985e enh: show command optimize 2022-08-11 20:26:40 +08:00
Xiaoyu Wang 4f0c6d3aa4 enh: show command optimize 2022-08-11 15:37:26 +08:00
Xiaoyu Wang f33959bd9b fix: some problems of parser 2022-08-02 20:20:44 +08:00
Xiaoyu Wang 5c9fbbd2e1 fix: some problems of parser and planner 2022-08-01 15:54:53 +08:00
Xiaoyu Wang f977117c6c fix: db options rename 2022-07-27 11:55:19 +08:00
Xiaoyu Wang 1ddbff0acf feat: add db options of wal 2022-07-25 21:09:06 +08:00
Xiaoyu Wang 37ec05a715 fix: memory leak problems of parser and planner 2022-07-20 17:20:29 +08:00
Xiaoyu Wang 5988fc0e4a feat: sql command 'show tags from table_name' 2022-07-19 15:31:44 +08:00
Xiaoyu Wang 7c585d8ed9 fix: database options 'strict' and 'cachelast' syntax adjustments 2022-07-16 11:47:26 +08:00
Xiaoyu Wang 43b5ca1efe feat: support pseudo columns such as _qstart, _qend and _qduration 2022-07-13 15:13:01 +08:00
Xiaoyu Wang 8b89492101 fix: some problems of parser 2022-07-12 15:11:55 +08:00
Xiaoyu Wang 0bc700eb82 feat: sql command 'trim database' 2022-07-11 10:53:06 +08:00
Xiaoyu Wang 5708d497ce fix: syntax issue with '(select ... limit) statement' 2022-07-11 10:07:11 +08:00
Xiaoyu Wang df06d22cb3 fix: some problem of parser and planner 2022-07-08 17:35:11 +08:00
Xiaoyu Wang 0bf399a67e merge 3.0 2022-07-06 18:53:54 +08:00
Xiaoyu Wang 025b7782e1 feat: add db option 'cachelastsize' 2022-07-06 18:47:33 +08:00
Haojun Liao 916dbebb00 other: merge 3.0 2022-07-06 13:49:39 +08:00
Xiaoyu Wang c8508248e2 feat: sql command 'insert ... select' 2022-07-05 21:12:10 +08:00
Haojun Liao 6bfe5df94a other: merge 3.0 2022-07-05 09:47:39 +08:00
Hongze Cheng ddb198de23 Merge branch '3.0' of https://github.com/taosdata/TDengine into feat/tsdb_refact 2022-07-04 03:42:50 +00:00
Xiaoyu Wang 988cffcce6 fix: some problems of parser and planner 2022-07-02 18:19:10 +08:00
Xiaoyu Wang 1530b33991 feat: support 'select *, expr from ...' syntax 2022-06-30 16:16:05 +08:00
Xiaoyu Wang 6141bb03da feat: insert from csv 2022-06-30 15:04:54 +08:00
Xiaoyu Wang 11a8f7f04d feat: sql command 'flush database' 2022-06-29 18:20:27 +08:00
Xiaoyu Wang ae076af4f1 feat: sql system info function 'database()', 'client_version()', 'server_version()', 'server_status()', 'current_user()' and 'user()' 2022-06-29 11:41:32 +08:00
Xiaoyu Wang 4fcd667bf6 feat: sql command 'show consumers' and 'show subscriptions' 2022-06-23 18:03:15 +08:00
Xiaoyu Wang acd1bbd8e3 merge 3.0 2022-06-22 17:00:11 +08:00
Xiaoyu Wang a5ca4965a4 feat: some sql syntax adjustments 2022-06-22 16:35:14 +08:00
Xiaoyu Wang eeab56e318 feat: sql command 'select constant' 2022-06-22 09:54:31 +08:00
Xiaoyu Wang 5c185b909a feat: sql command 'show local variables' and 'show dnode variables' 2022-06-20 20:36:15 +08:00
Xiaoyu Wang bac6e27c20 feat: sql command 'interp' 2022-06-19 19:39:12 +08:00
Xiaoyu Wang 22d1422b49 feat: sql command 'show table distributed' 2022-06-18 18:37:18 +08:00
Xiaoyu Wang 48f730fbcf feat: the sql command 'create dnode' is compatible with the 2.x version syntax 2022-06-18 14:49:36 +08:00
Xiaoyu Wang a06b329bee feat: sql command 'show create database', 'show create table', 'show create stable' and 'alter local' 2022-06-17 21:16:13 +08:00
Xiaoyu Wang aea4f9c69b feat: rollup options adjust 2022-06-17 17:27:42 +08:00
Xiaoyu Wang 97ac79f557 feat: rollup grammar adjust 2022-06-16 11:13:59 +08:00
Xiaoyu Wang 19ab15b19f feat: super table join 2022-06-15 13:49:29 +08:00
Xiaoyu Wang 380a071551 fix: handle the memory leak of parser 2022-06-13 14:54:38 +08:00