Commit graph

433 commits

Author SHA1 Message Date
xsren
bf9ea14f86 data check: udf 2024-11-11 11:04:11 +08:00
xsren
1c01bd801b param valid: udf 2024-11-11 09:23:02 +08:00
Shengliang Guan
0be118c0aa
Merge pull request #28408 from taosdata/enh/TD-32181/client
Enh/td 32181/client
2024-11-06 09:42:05 +08:00
dapan1121
9f2fba6269 Merge remote-tracking branch 'origin/main' into enh/TD-32190 2024-10-28 18:48:40 +08:00
xsren
323088dc71 fix: create partialfunction 2024-10-27 22:41:34 +08:00
Shengliang Guan
25d43c139c
Merge pull request #28363 from taosdata/feature/TS-5530
feat: data analysis
2024-10-21 19:51:24 +08:00
Shengliang Guan
4c6dfe3308
Merge pull request #28273 from taosdata/fix/3.0/TD-32184
fix:[TD-32184] Support backwards compatibility for function's result info.
2024-10-21 13:35:02 +08:00
dapan1121
a8965fa98c Merge remote-tracking branch 'origin/3.0' into enh/TD-32190 2024-10-15 19:20:36 +08:00
Shengliang Guan
3003e7286e feat: data analysis 2024-10-15 10:00:38 +08:00
Shengliang Guan
9f05ca5ee8 revert: data analysis 2024-10-14 23:27:11 +08:00
Jing Sima
06121e6c9d fix:[TD-32184] fix compile error. 2024-10-14 11:00:20 +08:00
Jing Sima
11ed8a1540 fix:[TD-32184] Support backwards compatibility for function's result info. 2024-10-14 11:00:20 +08:00
Jing Sima
6231d46cc5 enh:[TD-32189] Add validation to prevent changes to resultinfo structure. 2024-10-12 15:14:59 +08:00
Shengliang Guan
4dc0c2f47e feat: data analysis 2024-10-09 17:09:43 +08:00
dapan1121
c18da7f273 Merge remote-tracking branch 'origin/3.0' into enh/TD-32190 2024-09-30 09:55:09 +08:00
dapan1121
65985c7aaa enh: add tag scan test 2024-09-27 18:08:36 +08:00
Jing Sima
ad7b2ddc1b enh:[TD-32158] Free memory only when function need cleanup. 2024-09-24 11:35:36 +08:00
54liuyao
aa80aa39bc fix(query):use window start key when ts column is null 2024-09-12 15:34:57 +08:00
Jing Sima
02dd9c9160 fix:[TD-31818] fix memory leak allocated by mode function. 2024-09-03 17:34:23 +08:00
xsren
4b872f849c fmFuncDynDataRequired: only return state 2024-08-27 17:07:13 +08:00
sima
a54019211f feat:[TS-4893] Support MYSQL functions.
Add more functions:
 - Numeric Functions: PI(),ROUND(),TRUNC(),EXP(),LN(),SIGN(),DEGREES(),RADIANS().
 - String Functions: CHAR(),ASCII(),POSITION(),TRIM(),REPLACE(),REPEAT().
 - Date and Time Functions: WEEKDAY(),DAYOFWEEK(),WEEK(),WEEKOFYEAR().
 - Aggregate Functions: VAR_POP().
Modify some functions:
 - ROUND(): support round to given decimal places.
 - CHAR_LENGTH(): support calculate multi-byte character's length.
 - TIMEDIFF(): result will be negative when expr1 < expr2.
 - STDDEV(): add alias name STDDEV_POP().
 - SUBSTR(): add alias name SUBSTRING().
             support new syntax SUBSTRING/SUBSTR(expr FROM pos [FOR len]).
2024-08-14 09:19:25 +08:00
Shengliang Guan
8e81abe224 enh: get vardata len from udf api 2024-08-08 19:18:50 +08:00
Shengliang Guan
d55a0c7100 enh: enable log in udf 2024-08-08 16:18:18 +08:00
xsren
911e6380b9 return value: udf 2024-07-27 18:33:08 +08:00
Hongze Cheng
eaa3634764 enh: refactor error code 2024-07-25 08:51:19 +08:00
sima
1285100f68 enh:[TD-31043] Handling return value in functionMgt.c 2024-07-23 15:37:17 +08:00
sima
6a9441528a enh:[TD-31043] Handling return value in builtinsimpl.c 2024-07-23 15:37:17 +08:00
xsren
2a675ccf6b group const value func 2024-07-22 11:19:11 +08:00
xsren
ebe0074da4 fix: interp crash 2024-07-22 00:06:47 +08:00
54liuyao
113cb57326 adj stream operator result 2024-07-17 19:35:35 +08:00
dapan1121
e4c624f286
Merge pull request #26489 from taosdata/fix/3.0/TD-30819
feat:[TD-30819] Reduce memory usage when use percentile with interval.
2024-07-11 13:35:39 +08:00
sima
f17c535ca0 feat:[TD-30819] Reduce memory usage when using percentile with interval. 2024-07-10 19:43:19 +08:00
factosea
5f0ac46029 diff 2024-07-04 11:04:59 +08:00
Haojun Liao
6898eba6ed fix(stream): expand stream tasks are divided into two phase, the first is to build stream task and then expand stream task before start stream tasks. 2024-05-14 14:34:31 +08:00
wangjiaming0909
f6200dd923 support long ctb names 2024-04-16 14:25:34 +08:00
wangjiaming0909
fa85d1caa7 support other tsma funcs 2024-04-16 14:23:25 +08:00
wangjiaming0909
cc9550f45e add tsma funcs 2024-04-16 14:20:59 +08:00
wangjiaming0909
895a4584e6 generate tsma plan 2024-04-16 14:14:39 +08:00
wangjiaming0909
4b6fb0ffc6 tsma optimization 2024-04-16 14:14:39 +08:00
wangjiaming0909
0fd66d7e8a tsma optimization 2024-04-16 14:14:39 +08:00
wangjiaming0909
ef47fd57d6 support tsma catalog cache 2024-04-16 14:14:34 +08:00
dapan1121
55d118d17c Merge remote-tracking branch 'origin/3.0' into feat/TD-27337 2024-04-16 09:12:04 +08:00
54liuyao
1d42e927c6 Merge branch '3.0' of https://github.com/taosdata/TDengine into feat/TS-4243-3.0 2024-04-11 15:35:42 +08:00
54liuyao
e161556f51 set ts column index for function 2024-04-10 15:35:25 +08:00
dapan1121
8407eb3791 enh: outer join performance optimization 2024-04-09 09:48:38 +08:00
slzhou
b504627830 fix: new group block to reset func input iter hasPrev 2024-03-29 17:01:56 +08:00
slzhou
a5ba546bd4 fix: add pk to funcInputGetNextRow 2024-03-25 15:12:34 +08:00
slzhou
4d3eb6824c feat: add pk support for last/first/last_row dynDataRequired 2024-03-25 13:38:34 +08:00
shenglian zhou
cee96e2048 feat: begin coding function 2024-03-19 13:57:12 +08:00
wangmm0220
a8e45440c0 fix:conflicts from 3.0 2024-02-18 18:02:14 +08:00
Haojun Liao
0fe9c05c5f
Merge pull request #24704 from taosdata/fix/3_liaohj
fix(stream): take ver snapshot for all vgroups
2024-02-01 17:07:36 +08:00
Haojun Liao
cb2ea4a721 fix(stream): take ver snapshot for all vgroups before launching stream with fill-history option opened. 2024-02-01 11:37:57 +08:00
wangmm0220
a9fcc67321 fix:conflicts from 3.0 2024-02-01 11:13:03 +08:00
factosea
5d731dc9a4 fix: use blank data flag 2024-01-30 17:34:06 +08:00
wangmm0220
7246fedfef Merge branch '3.0' of https://github.com/taosdata/TDengine into feat/ly_multi_marks 2024-01-18 19:08:35 +08:00
facetosea
f010e18ff0 fix: LEASTSQUARES func result stack overflow 2024-01-17 18:28:00 +08:00
wangmm0220
2ab54a1335 fix:conflicts from 3.0 2024-01-15 16:54:52 +08:00
54liuyao
52d8811bdc code coverage 2024-01-12 13:49:32 +08:00
wangmm0220
eac86f72b3 fix:partical func parameters for middle interval[checkStreamSTable1.sim] 2023-12-22 18:30:22 +08:00
Alex Duan
1fa6cb8f69 coverage: isRowEntryCompleted had been called 5200w hits 2023-12-21 15:10:21 +08:00
yihaoDeng
a82856dff7 fix mem leak 2023-12-05 20:28:12 +08:00
liuyao
467c27c758 recover flush mark 2023-11-07 15:45:38 +08:00
wangjiaming0909
f299a28109 feat: support to_timestamp/to_char 2023-10-23 19:36:03 +08:00
wangjiaming0909
1e53e6cfeb optimize count()/last() + partition by tbname/tag 2023-09-19 14:56:02 +08:00
dapan1121
2e7897239a fix: trim block and partition by constant function issue 2023-08-30 16:51:44 +08:00
Haojun Liao
88f6596965
Merge pull request #22464 from taosdata/feat/TD-18789
feat:support varbinary type
2023-08-28 09:45:57 +08:00
dapan1121
3045a623e1 Merge remote-tracking branch 'origin/3.0' into feat/TD-24700 2023-08-17 14:16:05 +08:00
wangmm0220
dbc1b35d44 feat:support varbinary type 2023-08-16 19:57:01 +08:00
Ganlin Zhao
01a7dfbc34 feat: add irate distributed execution 2023-08-15 12:59:30 +08:00
dapan1121
c85bbef2e9 Merge remote-tracking branch 'origin/3.0' into feat/TD-24700 2023-07-05 11:13:57 +08:00
Haojun Liao
200575647c
Merge branch '3.0' into refact/fillhistory 2023-07-03 15:16:18 +08:00
dapan1121
7dddfd0a5a Merge remote-tracking branch 'origin/3.0' into feat/TD-24700 2023-06-29 19:29:27 +08:00
dapan1121
3519e9170e Merge remote-tracking branch 'origin/main' into 3.0 2023-06-29 11:13:45 +08:00
dapan1121
9f0da17c49 Merge remote-tracking branch 'origin/3.0' into feat/TD-24700 2023-06-28 19:40:55 +08:00
Haojun Liao
3289ad62be other: merge 3.0 2023-06-27 11:33:40 +08:00
dapan1121
4dae9f4eff merge main to 3.0 2023-06-26 18:43:00 +08:00
dapan1121
ce2635074d enh: add uid/vgid functions 2023-06-26 11:48:47 +08:00
shenglian zhou
fd754eaa08 fix: udfd can not connect to taosd since authentification failure 2023-06-25 11:31:33 +08:00
yihaoDeng
0eeaab9cd3 Merge branch 'refact/fillhistory1' into refact/fillhistory 2023-06-19 13:53:37 +08:00
yihaoDeng
0ef8afbdaa support fill history 2023-06-16 09:32:38 +08:00
yihaoDeng
9f9171719a support fill history 2023-06-15 21:29:52 +08:00
Ganlin Zhao
e79d63d766 add error code 2023-06-14 13:34:25 +08:00
dapan1121
73d3c21e21 Merge remote-tracking branch 'origin/3.0' into feat/TD-24499 2023-06-13 11:44:41 +08:00
dapan1121
170182fecd feat: support fill history with sub request 2023-06-12 16:10:54 +08:00
yihaoDeng
74d5f02969 fix invalid free 2023-06-05 04:56:07 +00:00
yihaoDeng
479a117266 Merge branch 'enh/dev3.0' into enh/addCompileError 2023-05-26 13:03:47 +00:00
Haojun Liao
cea8334427
Merge pull request #21449 from taosdata/refact/fillhistory
refactor: remove the module dependency.  TD-24279
2023-05-26 09:01:45 +08:00
Haojun Liao
0966213847 fix(arch): set the correct module api dependency. 2023-05-25 14:21:40 +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
Haojun Liao
041ffa91bd other: merge main. 2023-05-17 15:42:15 +08:00
dapan1121
0dd0b16842 enh: optimize table scan for last query 2023-05-12 13:30:17 +08:00
kailixu
50053fdc01 Merge branch '3.0' into enh/TD-21161-3.0 2023-04-18 11:13:30 +08:00
Haojun Liao
02ec67ad9e
Merge pull request #20882 from taosdata/fix/TS-3081
fix:open test cases for tmq & add log if rebalance error
2023-04-14 17:56:58 +08:00
wangmm0220
e985f15cf0 fix:memset nullBitmap of SSDataBlock to 0 in udf 2023-04-14 09:36:36 +08:00
dapan1121
d4cb608505
Merge pull request #20885 from taosdata/fix/TS-3108
fix: fix timestamp constant comparison precision error
2023-04-14 09:27:03 +08:00
Ganlin Zhao
7414f28d17 fix translatefunc not getting precision issue 2023-04-13 11:22:15 +08:00
kailixu
04fa4d2e87 Merge branch '3.0' into enh/TD-21161-3.0 2023-04-12 13:05:47 +08:00
Xiaoyu Wang
5ce6220106
Merge pull request #20781 from taosdata/szhou/replace-function
feature: udf replace function
2023-04-11 17:25:21 +08:00
shenglian zhou
32523d72f9 fix: add created time to file name and keep file reuse 2023-04-08 10:11:57 +08:00
kailixu
e976fcb91d Merge branch '3.0' into enh/TD-21161-3.0 2023-04-07 17:51:35 +08:00