Commit Graph

625 Commits

Author SHA1 Message Date
dapan1121 ce2635074d enh: add uid/vgid functions 2023-06-26 11:48:47 +08:00
Ganlin Zhao 77d2737f91 fix: fix userAlias issue when keepColumnName is set to true 2023-06-25 17:51:51 +08:00
wangjiaming0909 fb4f174fbc feature: add input, output ts order for execution plans 2023-06-16 10:26:09 +08:00
dapan1121 e52c6aae8c
Merge pull request #21620 from taosdata/fix/TD-24567-3.0
fix: tsma query with order by _wstart/_wend
2023-06-15 09:06:57 +08:00
kailixu 4cd039c38e chore: compare funcNode without aliasName 2023-06-12 16:47:03 +08:00
dapan1121 170182fecd feat: support fill history with sub request 2023-06-12 16:10:54 +08:00
dapan1121 ddd3a53e56 Merge remote-tracking branch 'origin/3.0' into fix/TD-24001 2023-06-02 13:57:34 +08:00
Haojun Liao d45aa7ef84
Merge pull request #21555 from taosdata/fix/liaohj_main
other: merge main into 3.0.
2023-06-02 13:11:12 +08:00
Haojun Liao 5301c5756a other: merge main into 3.0. 2023-06-01 09:29:18 +08:00
wangmm0220 5d2c78ba6b fix:memory leak 2023-05-30 10:39:00 +08:00
dapan1121 e70c433a59 enh: support time line query from union/union all subquery 2023-05-26 08:44:23 +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
dapan1121 4c88fd08de Merge remote-tracking branch 'origin/3.0' into fix/TD-24001 2023-05-23 09:25:37 +08:00
slzhou f9da4abdcb fix: change more variable names 2023-05-19 15:38:52 +08:00
shenglian zhou f36b0be17d fix: join eq conditions not only for tag 2023-05-19 14:32:03 +08:00
wade zhang 1ade314043
Merge pull request #21325 from taosdata/feat/force-drop-dnode
Feat/force drop dnode
2023-05-19 09:23:54 +08:00
slzhou 304423e27b Merge branch 'main' of github.com:taosdata/TDengine into szhou/fix-ts3405 2023-05-18 13:27:58 +08:00
dapan1121 5ac91597b6
Merge pull request #21310 from wangjiaming0909/fix/TS-3398
fix: select <expr1>, <expr1##sth else> from ... return error data whe…
2023-05-18 10:07:06 +08:00
Haojun Liao 041ffa91bd other: merge main. 2023-05-17 15:42:15 +08:00
dapan1121 ab7cb995a2 fix: join push down condition issue 2023-05-17 15:31:53 +08:00
wangjiaming0909 789b0c7178 fix: select <expr1>, <expr1##sth else> from ... return error data when strlen(expr1) > TSDB_COL_NAME_LEN 2023-05-16 15:42:30 +08:00
dapan1121 cf7b4593e7 feat: add drop dnode unsafe command 2023-05-16 09:50:10 +08:00
shenglian zhou 629ab2b85f fix: extract tag equal condition 2023-05-15 16:10:11 +08:00
Haojun Liao 99148d6719 other: merge 3.0 2023-05-13 20:02:48 +08:00
dapan1121 69795286fa Merge remote-tracking branch 'origin/main' into enh/tsbsPerf.4 2023-05-12 13:46:16 +08:00
yihaoDeng 5708fcb5cb Merge branch 'enh/3.0' into enh/rocksdbSstateMerge 2023-05-10 08:02:16 +00:00
dapan1121 eb7cd25e2e enh: support nest partition by clause 2023-05-10 14:34:41 +08:00
dapan1121 a8c65cd25a feat: support restore dnode clause 2023-05-09 19:19:14 +08:00
dapan1121 7ea23a33bc enh: optimize time line function validation 2023-05-09 16:37:08 +08:00
dapan1121 a1eefd25ea fix: count wrong group number issue 2023-05-09 11:33:47 +08:00
liuyao 2984c5a758 merge main 2023-04-28 10:34:46 +08:00
Xiaoyu Wang e584bb3ea1 feat: subtable level privilege 2023-04-25 17:39:28 +08:00
Xiaoyu Wang dc5235eb92 feat: add pause/resume stream statement 2023-04-24 14:48:33 +08:00
Xiaoyu Wang 4bb7a25fc7 feat: subtable level privilege 2023-04-23 16:30:28 +08:00
chenhaoran 7d7a0769b3 Merge remote-tracking branch 'origin/main' into enh/tsbsPerf.1 2023-04-21 16:20:37 +08:00
dapan1121 ed3778dc9f fix: nodes free issue 2023-04-17 15:44:15 +08:00
Xiaoyu Wang 58d9f615fe fix: udf plan error 2023-04-14 19:54:04 +08:00
Xiaoyu Wang 4c04b155d5 merge main 2023-04-11 15:56:28 +08:00
Xiaoyu Wang f44c219360 feat: table level privilege 2023-04-07 11:15:05 +08:00
Xiaoyu Wang eb79046a70 merge 3.0 2023-03-22 11:42:02 +08:00
cadem ea35f0ae11 feat/balance vgroup leader 2023-03-22 09:36:59 +08:00
Xiaoyu Wang 58ebd3539d feat: alter database wal_retention_period/wal_retention_size 2023-03-21 16:45:19 +08:00
dapan1121 273d0c0c07 fix: all columns are invisiable in system table query 2023-03-09 10:40:27 +08:00
Alex Duan 3249b83890 fix: destroy node with wrong type coversion 2023-02-28 17:38:35 +08:00
Xiaoyu Wang 5b7ec8ade5 fix: invalid write memory when query policy is 4 2023-02-28 10:41:13 +08:00
Haojun Liao 22aa03307c fix(query): fix syntax errors on centos. 2023-02-24 11:38:54 +08:00
Xiaoyu Wang c597de099f merge main 2023-02-20 13:41:27 +08:00
Xiaoyu Wang de92def988 fix: query compatible with lower version messages 2023-02-13 15:25:00 +08:00
Xiaoyu Wang 3382a24a69 merge main 2023-02-10 18:03:11 +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 79440f7a26
Merge pull request #19860 from taosdata/fix/3.0_merge_main
merge main
2023-02-09 09:22:19 +08:00
Xiaoyu Wang 57ffc1b540 feat: add ignore update option for create stream 2023-02-08 18:55:42 +08:00
Xiaoyu Wang 98e2fa2d7b feat: add ignore update option for create stream 2023-02-08 18:46:12 +08:00
Hongze Cheng 5a56e39613 Merge branch '3.0' of https://github.com/taosdata/TDengine into feat/vnode_compact 2023-02-08 11:15:51 +08:00
Xiaoyu Wang 09925437e3 merge main 2023-02-08 09:51:52 +08:00
Xiaoyu Wang 8b6a50d970 feat: add explain test case 2023-02-07 18:35:42 +08:00
Xiaoyu Wang f2ff17dace merge 3.0 2023-02-06 14:18:13 +08:00
dapan1121 d88f1efeb1 feat: support force fill clause 2023-02-02 17:16:30 +08:00
Xiaoyu Wang 024824fb3d fix: event_window memory leak 2023-02-01 09:34:14 +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 0c422345b3 feat: support show cluster alive; and show db.alive; 2022-12-29 18:07:57 +08:00
Ganlin Zhao b55af6372c fix(query): fix count/hyperloglog return additional row in group by
when queryPolicy is set to 3.
2022-12-28 17:28:40 +08:00
Hongze Cheng a0fa31954c Merge branch '3.0' of https://github.com/taosdata/TDengine into feat/vnode_compact 2022-12-28 13:53:59 +08:00
Xiaoyu Wang b52ebb6fd5 feat: sql command 'compact database' 2022-12-27 11:11:02 +08:00
Haojun Liao 723efba79b
Merge branch '3.0' into refact/submit_req 2022-12-26 13:25:25 +08:00
Shengliang Guan 664dcb6b4e Merge branch 'main' into merge/mainto3.0_1226 2022-12-26 09:26:54 +08:00
Xiaoyu Wang 0c269c317b merge 3.0 2022-12-23 17:50:05 +08:00
Xiaoyu Wang 72fe37888f enh: improve unit tests 2022-12-21 17:24:54 +08:00
Xiaoyu Wang aecd05cf34 enh: improve unit tests 2022-12-21 13:51:06 +08:00
Xiaoyu Wang ad7f9b274b enh: improve unit tests 2022-12-20 16:53:08 +08:00
Xiaoyu Wang c6701221d6 enh: improve unit tests 2022-12-20 12:46:26 +08:00
Haojun Liao fdade6d6a3
Merge branch '3.0' into refact/submit_req 2022-12-19 11:24:00 +08:00
dapan1121 978d45ffc1 enh: optimize converting timestamp at client side 2022-12-15 16:56:35 +08:00
Xiaoyu Wang 2f9753c540 event window query 2022-12-13 14:18:03 +08:00
Xiaoyu Wang bc36bc188e feat: event window 2022-12-08 09:36:37 +08:00
Hongze Cheng 2d85c7c451 Merge branch '3.0' of https://github.com/taosdata/TDengine into refact/submit_req 2022-12-07 09:04:00 +08:00
Xiaoyu Wang bc413b8fff feat: add stream option 'delete_mark' 2022-12-06 16:07:11 +08:00
Hongze Cheng 899d7b0bcc Merge branch '3.0' of https://github.com/taosdata/TDengine into refact/submit_req 2022-12-06 14:37:22 +08:00
Shengliang Guan d9c261cd13 refact: remove some error codes 2022-12-03 10:17:02 +08:00
Xiaoyu Wang 85ea8bbbb3 Merge remote-tracking branch 'origin/3.0' into enh/3.0_planner_optimize 2022-12-02 14:04:50 +08:00
Hongze Cheng f9870c3637 Merge branch '3.0' of https://github.com/taosdata/TDengine into refact/submit_req 2022-12-01 14:24:29 +08:00
Xiaoyu Wang 4e8acca2eb feat: sql command 'show user privileges' 2022-11-30 19:24:15 +08:00
slzhou 323e52b8c5 Merge branch 'enh/3.0_planner_optimize' into szhou/table-count-scan 2022-11-30 15:43:41 +08:00
slzhou 259b893f0a fix: integration test of table count scan 2022-11-30 15:42:45 +08:00
Xiaoyu Wang cfbcf92c1f Merge remote-tracking branch 'origin/3.0' into enh/3.0_planner_optimize 2022-11-30 14:29:34 +08:00
Xiaoyu Wang 173794dc0f merge 3.0 2022-11-30 10:58:32 +08:00
Xiaoyu Wang f3681433c6 fix: stream plan error 2022-11-29 16:43:12 +08:00
Xiaoyu Wang 555f2cb981 merge 3.0 2022-11-29 13:16:54 +08:00
Xiaoyu Wang 0c137f3a79 merge refact/submit_req 2022-11-27 23:07:47 +08:00
Xiaoyu Wang 948502be25 enh: replace row format 2022-11-27 17:09:02 +08:00
Xiaoyu Wang 70164f9f20 enh: group by tbname optimize 2022-11-24 15:16:38 +08:00
Xiaoyu Wang bc180e39c9 enh: ins_tables optimize 2022-11-22 16:39:30 +08:00
Xiaoyu Wang d00f65a8fe Merge remote-tracking branch 'origin/3.0' into enh/3.0_planner_optimize 2022-11-18 15:05:19 +08:00
Xiaoyu Wang dc0d3745a7 enh: fill value supports implicit type conversion 2022-11-17 15:48:42 +08:00
Xiaoyu Wang 6a50e9e271 Merge remote-tracking branch 'origin/3.0' into enh/3.0_planner_optimize 2022-11-16 10:58:06 +08:00
Xiaoyu Wang 40c7562470 enh: optimize statement for querying the number of sub tables of the super table 2022-11-15 16:38:51 +08:00
Xiaoyu Wang 901c9b8f77 fix: some problems of parser 2022-11-14 16:53:01 +08:00
Xiaoyu Wang 38f20ec32d enh: show table tags command extension 2022-11-10 17:22:13 +08:00
Xiaoyu Wang 80dc658dbb Merge remote-tracking branch 'origin/3.0' into enh/3.0_planner_optimize 2022-11-04 18:03:21 +08:00
Xiaoyu Wang 8513dc1067 enh: insert optimize 2022-11-04 15:21:38 +08:00
Xiaoyu Wang e8c0515dce enh: flag of whether the subplan is added as a show statement 2022-10-28 10:46:04 +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
dapan1121 a80f382c5d fix: fix tsc query memory leak 2022-10-21 17:00:11 +08:00
Haojun Liao abff4fb1f2
Merge pull request #17336 from taosdata/feature/3_liaohj
other:merge 3.0, and support last query cache
2022-10-20 18:15:38 +08:00
Xiaoyu Wang 601f0f3edf fix: handle coverity scan 2022-10-19 13:56:39 +08:00
Haojun Liao aa9c99fa53 Merge branch '3.0' into feature/3_liaohj 2022-10-16 12:50:05 +08:00
Xiaoyu Wang ab98754c56 Merge remote-tracking branch 'origin/3.0' into enh/3.0_planner_optimize 2022-10-14 13:45:15 +08:00
dapan1121 f3919c4450 Merge remote-tracking branch 'origin/3.0' into feat/caseWhen 2022-10-14 09:14:01 +08:00
Xiaoyu Wang 242a53c285 enh: do coverity scan 2022-10-13 17:03:40 +08:00
Xiaoyu Wang 7a19119dc7 Merge remote-tracking branch 'origin/3.0' into enh/3.0_planner_optimize 2022-10-13 16:44:41 +08:00
Xiaoyu Wang 3cce178721 enh: do coverity scan 2022-10-13 16:43:56 +08:00
Haojun Liao 18740e7b48 other:merge 3.0, and support last query cache 2022-10-13 15:35:51 +08:00
Xiaoyu Wang d6374a726a fix: some problems of parser 2022-10-12 16:32:29 +08:00
dapan1121 55a26990da feat: support case when cases 2022-10-08 19:07:43 +08:00
Xiaoyu Wang 73642ac3a2 feat: sql command 'show table tags from table_name' 2022-09-29 16:16:49 +08:00
Xiaoyu Wang 5d0357fc47 fix: very long string serialization problem 2022-09-29 11:14:35 +08:00
54liuyao 747297bd28 feat(stream): stream fill 2022-09-27 18:11:44 +08:00
Xiaoyu Wang 1d62834e5c feat(stream): tag and child table name improvement 2022-09-26 18:39:47 +08:00
dapan1121 dc0e36f742
Merge branch '3.0' into enh/clientPolicy 2022-09-23 16:41:18 +08:00
Shengliang Guan 778aa44fc2
Merge pull request #17018 from taosdata/fix/3.0_bugfix_wxy
fix: subplans under set operator use different group ids
2022-09-23 14:03:05 +08:00
dapan1121 3fb3aa7bea Merge remote-tracking branch 'origin/3.0' into enh/clientPolicy 2022-09-23 13:33:11 +08:00
Shengliang Guan f80068bbe6
Merge pull request #17011 from taosdata/feat/3.0_parser_planner
feat: case when expression
2022-09-23 11:41:57 +08:00
Xiaoyu Wang ee9190e9c0 fix: subplans under set operator use different group ids 2022-09-23 11:26:03 +08:00
Xiaoyu Wang 50ebcb5006 feat: case when expression 2022-09-22 19:20:21 +08:00
Xiaoyu Wang 0321b8c088 fix: avg function data scan optimization 2022-09-22 15:08:07 +08:00
Xiaoyu Wang 5116e0a01b enh: added memory allocators for parser and planner 2022-09-21 17:04:12 +08:00
Xiaoyu Wang a914816ce7 enh: added memory allocators for parser and planner 2022-09-21 11:28:34 +08:00
Xiaoyu Wang 2f475399a6 enh: added memory allocators for parser and planner 2022-09-21 10:57:41 +08:00
Xiaoyu Wang 46b0c2c9c4 enh: added memory allocators for parser and planner 2022-09-20 18:52:45 +08:00
Xiaoyu Wang 8a010a58f3 enh: added memory allocators for parser and planner 2022-09-20 16:13:08 +08:00
Xiaoyu Wang d1d55f4e78 enh: physical plan serialization supports cross-platform 2022-09-19 16:50:00 +08:00
Xiaoyu Wang 74f75893ea enh: physical plan serialization supports cross-platform 2022-09-19 15:56:14 +08:00
Xiaoyu Wang 70bc3e6984 enh: plan serialization optimize 2022-09-19 14:21:41 +08:00
Shengliang Guan 755a175118
Merge pull request #16874 from taosdata/enh/3.0_plan_msg
enh: plan serialization optimize
2022-09-16 19:58:23 +08:00
Xiaoyu Wang 2992f50175 enh: plan serialization optimize 2022-09-16 10:10:24 +08:00
Xiaoyu Wang b9a2d3251c enh: plan serialization optimize 2022-09-15 22:45:03 +08:00
dapan1121 4048c99282 Merge remote-tracking branch 'origin/3.0' into enh/clientPolicy 2022-09-15 14:50:35 +08:00
Xiaoyu Wang e2586979eb enh: the delete physical plan increases the timestamp interval of the actual deleted data 2022-09-14 17:51:21 +08:00
Xiaoyu Wang fbcef61d06 enh: add binary serialization method to node structure 2022-09-14 10:34:13 +08:00
Xiaoyu Wang 26a1bb437c enh: add binary serialization method to node structure 2022-09-13 16:53:26 +08:00
Xiaoyu Wang 82fcd22107 enh: add binary serialization method to node structure 2022-09-13 15:57:17 +08:00
Xiaoyu Wang f40d838fe7 enh: add binary serialization method to node structure 2022-09-13 15:07:31 +08:00
Xiaoyu Wang f32a17580c enh: add binary serialization method to node structure 2022-09-13 13:31:35 +08:00
Xiaoyu Wang ff9d673489 enh: add binary serialization method to node structure 2022-09-13 10:48:39 +08:00
dapan1121 1427a8f3b0 enh: support client query policy 2022-09-09 19:03:42 +08:00
Xiaoyu Wang d66bb918a4 enh: add binary serialization method to node structure 2022-09-09 08:30:45 +08:00
Xiaoyu Wang 3f5746d20b enh: add binary serialization method to node structure 2022-09-08 15:43:14 +08:00