Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
3ca28608
T
TDengine
项目概览
taosdata
/
TDengine
1 年多 前同步成功
通知
1185
Star
22016
Fork
4786
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
1
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
T
TDengine
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
1
Issue
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
未验证
提交
3ca28608
编写于
6月 23, 2022
作者:
wmmhello
提交者:
GitHub
6月 23, 2022
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #14115 from taosdata/feature/3.0_wxy
feat: filter by tag
上级
bf307fbd
5200bf12
变更
6
隐藏空白更改
内联
并排
Showing
6 changed file
with
14 addition
and
15 deletion
+14
-15
source/libs/executor/inc/executorimpl.h
source/libs/executor/inc/executorimpl.h
+1
-2
source/libs/executor/src/executorimpl.c
source/libs/executor/src/executorimpl.c
+1
-1
source/libs/executor/src/scanoperator.c
source/libs/executor/src/scanoperator.c
+1
-1
source/libs/scalar/test/scalar/scalarTests.cpp
source/libs/scalar/test/scalar/scalarTests.cpp
+8
-8
tests/system-test/2-query/json_tag.py
tests/system-test/2-query/json_tag.py
+1
-1
tests/system-test/simpletest.bat
tests/system-test/simpletest.bat
+2
-2
未找到文件。
source/libs/executor/inc/executorimpl.h
浏览文件 @
3ca28608
...
@@ -838,8 +838,7 @@ int32_t finalizeResultRowIntoResultDataBlock(SDiskbasedBuf* pBuf, SResultRowPosi
...
@@ -838,8 +838,7 @@ int32_t finalizeResultRowIntoResultDataBlock(SDiskbasedBuf* pBuf, SResultRowPosi
SSDataBlock
*
pBlock
,
SExecTaskInfo
*
pTaskInfo
);
SSDataBlock
*
pBlock
,
SExecTaskInfo
*
pTaskInfo
);
int32_t
createScanTableListInfo
(
STableScanPhysiNode
*
pTableScanNode
,
SReadHandle
*
pHandle
,
int32_t
createScanTableListInfo
(
STableScanPhysiNode
*
pTableScanNode
,
SReadHandle
*
pHandle
,
STableListInfo
*
pTableListInfo
,
uint64_t
queryId
,
uint64_t
taskId
,
STableListInfo
*
pTableListInfo
,
uint64_t
queryId
,
uint64_t
taskId
);
SNode
*
pTagCond
);
SOperatorInfo
*
createGroupSortOperatorInfo
(
SOperatorInfo
*
downstream
,
SGroupSortPhysiNode
*
pSortPhyNode
,
SOperatorInfo
*
createGroupSortOperatorInfo
(
SOperatorInfo
*
downstream
,
SGroupSortPhysiNode
*
pSortPhyNode
,
SExecTaskInfo
*
pTaskInfo
);
SExecTaskInfo
*
pTaskInfo
);
SOperatorInfo
*
createTableMergeScanOperatorInfo
(
STableScanPhysiNode
*
pTableScanNode
,
STableListInfo
*
pTableListInfo
,
SOperatorInfo
*
createTableMergeScanOperatorInfo
(
STableScanPhysiNode
*
pTableScanNode
,
STableListInfo
*
pTableListInfo
,
...
...
source/libs/executor/src/executorimpl.c
浏览文件 @
3ca28608
...
@@ -4022,7 +4022,7 @@ SOperatorInfo* createOperatorTree(SPhysiNode* pPhyNode, SExecTaskInfo* pTaskInfo
...
@@ -4022,7 +4022,7 @@ SOperatorInfo* createOperatorTree(SPhysiNode* pPhyNode, SExecTaskInfo* pTaskInfo
return
pOperator
;
return
pOperator
;
}
else
if
(
QUERY_NODE_PHYSICAL_PLAN_TABLE_MERGE_SCAN
==
type
)
{
}
else
if
(
QUERY_NODE_PHYSICAL_PLAN_TABLE_MERGE_SCAN
==
type
)
{
STableMergeScanPhysiNode
*
pTableScanNode
=
(
STableMergeScanPhysiNode
*
)
pPhyNode
;
STableMergeScanPhysiNode
*
pTableScanNode
=
(
STableMergeScanPhysiNode
*
)
pPhyNode
;
createScanTableListInfo
(
pTableScanNode
,
pHandle
,
pTableListInfo
,
queryId
,
taskId
,
pTagCond
);
createScanTableListInfo
(
pTableScanNode
,
pHandle
,
pTableListInfo
,
queryId
,
taskId
);
extractTableSchemaVersion
(
pHandle
,
pTableScanNode
->
scan
.
uid
,
pTaskInfo
);
extractTableSchemaVersion
(
pHandle
,
pTableScanNode
->
scan
.
uid
,
pTaskInfo
);
SOperatorInfo
*
pOperator
=
createTableMergeScanOperatorInfo
(
pTableScanNode
,
pTableListInfo
,
pHandle
,
pTaskInfo
,
queryId
,
taskId
);
SOperatorInfo
*
pOperator
=
createTableMergeScanOperatorInfo
(
pTableScanNode
,
pTableListInfo
,
pHandle
,
pTaskInfo
,
queryId
,
taskId
);
STableScanInfo
*
pScanInfo
=
pOperator
->
info
;
STableScanInfo
*
pScanInfo
=
pOperator
->
info
;
...
...
source/libs/executor/src/scanoperator.c
浏览文件 @
3ca28608
...
@@ -1968,7 +1968,7 @@ int32_t compareTableKeyInfoByGid(const void* p1, const void* p2) {
...
@@ -1968,7 +1968,7 @@ int32_t compareTableKeyInfoByGid(const void* p1, const void* p2) {
}
}
int32_t
createScanTableListInfo
(
STableScanPhysiNode
*
pTableScanNode
,
SReadHandle
*
pHandle
,
int32_t
createScanTableListInfo
(
STableScanPhysiNode
*
pTableScanNode
,
SReadHandle
*
pHandle
,
STableListInfo
*
pTableListInfo
,
uint64_t
queryId
,
uint64_t
taskId
,
SNode
*
pTagCond
)
{
STableListInfo
*
pTableListInfo
,
uint64_t
queryId
,
uint64_t
taskId
)
{
int32_t
code
=
getTableList
(
pHandle
->
meta
,
&
pTableScanNode
->
scan
,
pTableListInfo
);
int32_t
code
=
getTableList
(
pHandle
->
meta
,
&
pTableScanNode
->
scan
,
pTableListInfo
);
if
(
code
!=
TSDB_CODE_SUCCESS
)
{
if
(
code
!=
TSDB_CODE_SUCCESS
)
{
return
code
;
return
code
;
...
...
source/libs/scalar/test/scalar/scalarTests.cpp
浏览文件 @
3ca28608
...
@@ -1310,11 +1310,11 @@ TEST(columnTest, json_column_logic_op) {
...
@@ -1310,11 +1310,11 @@ TEST(columnTest, json_column_logic_op) {
printf
(
"--------------------json string--0 {1, 8, 2, 2, 3, 0, 0, 0, 0}-------------------
\n
"
);
printf
(
"--------------------json string--0 {1, 8, 2, 2, 3, 0, 0, 0, 0}-------------------
\n
"
);
key
=
"k2"
;
key
=
"k2"
;
bool
eRes1
[
len
+
len1
]
=
{
false
,
false
,
true
,
tru
e
,
false
,
false
,
false
,
true
,
false
,
true
,
false
,
true
,
true
};
bool
eRes1
[
len
+
len1
]
=
{
false
,
false
,
false
,
fals
e
,
false
,
false
,
false
,
true
,
false
,
true
,
false
,
true
,
true
};
for
(
int
i
=
0
;
i
<
len
;
i
++
){
for
(
int
i
=
0
;
i
<
len
;
i
++
){
makeCalculate
(
row
,
key
,
TSDB_DATA_TYPE_INT
,
&
input
[
i
],
eRes1
[
i
],
op
[
i
],
false
);
makeCalculate
(
row
,
key
,
TSDB_DATA_TYPE_INT
,
&
input
[
i
],
eRes1
[
i
],
op
[
i
],
false
);
}
}
bool
eRes_1
[
len0
]
=
{
true
,
tru
e
,
false
,
false
,
false
,
false
};
bool
eRes_1
[
len0
]
=
{
false
,
fals
e
,
false
,
false
,
false
,
false
};
for
(
int
i
=
0
;
i
<
len0
;
i
++
){
for
(
int
i
=
0
;
i
<
len0
;
i
++
){
makeCalculate
(
row
,
key
,
TSDB_DATA_TYPE_INT
,
&
input
[
i
],
eRes_1
[
i
],
op
[
i
],
true
);
makeCalculate
(
row
,
key
,
TSDB_DATA_TYPE_INT
,
&
input
[
i
],
eRes_1
[
i
],
op
[
i
],
true
);
}
}
...
@@ -1346,11 +1346,11 @@ TEST(columnTest, json_column_logic_op) {
...
@@ -1346,11 +1346,11 @@ TEST(columnTest, json_column_logic_op) {
printf
(
"--------------------json bool--1 {1, 8, 2, 2, 3, 0, 0, 0, 0}-------------------
\n
"
);
printf
(
"--------------------json bool--1 {1, 8, 2, 2, 3, 0, 0, 0, 0}-------------------
\n
"
);
key
=
"k4"
;
key
=
"k4"
;
bool
eRes3
[
len
+
len1
]
=
{
false
,
false
,
true
,
true
,
false
,
tru
e
,
false
,
true
,
true
,
false
,
false
,
false
,
false
};
bool
eRes3
[
len
+
len1
]
=
{
false
,
false
,
false
,
false
,
false
,
fals
e
,
false
,
true
,
true
,
false
,
false
,
false
,
false
};
for
(
int
i
=
0
;
i
<
len
;
i
++
){
for
(
int
i
=
0
;
i
<
len
;
i
++
){
makeCalculate
(
row
,
key
,
TSDB_DATA_TYPE_INT
,
&
input
[
i
],
eRes3
[
i
],
op
[
i
],
false
);
makeCalculate
(
row
,
key
,
TSDB_DATA_TYPE_INT
,
&
input
[
i
],
eRes3
[
i
],
op
[
i
],
false
);
}
}
bool
eRes_3
[
len0
]
=
{
false
,
true
,
false
,
false
,
false
,
tru
e
};
bool
eRes_3
[
len0
]
=
{
false
,
false
,
false
,
false
,
false
,
fals
e
};
for
(
int
i
=
0
;
i
<
len0
;
i
++
){
for
(
int
i
=
0
;
i
<
len0
;
i
++
){
makeCalculate
(
row
,
key
,
TSDB_DATA_TYPE_INT
,
&
input
[
i
],
eRes_3
[
i
],
op
[
i
],
true
);
makeCalculate
(
row
,
key
,
TSDB_DATA_TYPE_INT
,
&
input
[
i
],
eRes_3
[
i
],
op
[
i
],
true
);
}
}
...
@@ -1419,11 +1419,11 @@ TEST(columnTest, json_column_logic_op) {
...
@@ -1419,11 +1419,11 @@ TEST(columnTest, json_column_logic_op) {
printf
(
"--------------------json bool-- 0 {1, 8, 2, 2, 3, 0, 0, 0, 0}-------------------
\n
"
);
printf
(
"--------------------json bool-- 0 {1, 8, 2, 2, 3, 0, 0, 0, 0}-------------------
\n
"
);
key
=
"k8"
;
key
=
"k8"
;
bool
eRes7
[
len
+
len1
]
=
{
false
,
false
,
true
,
tru
e
,
false
,
false
,
false
,
true
,
false
,
false
,
false
,
false
,
false
};
bool
eRes7
[
len
+
len1
]
=
{
false
,
false
,
false
,
fals
e
,
false
,
false
,
false
,
true
,
false
,
false
,
false
,
false
,
false
};
for
(
int
i
=
0
;
i
<
len
;
i
++
){
for
(
int
i
=
0
;
i
<
len
;
i
++
){
makeCalculate
(
row
,
key
,
TSDB_DATA_TYPE_INT
,
&
input
[
i
],
eRes7
[
i
],
op
[
i
],
false
);
makeCalculate
(
row
,
key
,
TSDB_DATA_TYPE_INT
,
&
input
[
i
],
eRes7
[
i
],
op
[
i
],
false
);
}
}
bool
eRes_7
[
len0
]
=
{
true
,
tru
e
,
false
,
false
,
false
,
false
};
bool
eRes_7
[
len0
]
=
{
false
,
fals
e
,
false
,
false
,
false
,
false
};
for
(
int
i
=
0
;
i
<
len0
;
i
++
)
{
for
(
int
i
=
0
;
i
<
len0
;
i
++
)
{
makeCalculate
(
row
,
key
,
TSDB_DATA_TYPE_INT
,
&
input
[
i
],
eRes_7
[
i
],
op
[
i
],
true
);
makeCalculate
(
row
,
key
,
TSDB_DATA_TYPE_INT
,
&
input
[
i
],
eRes_7
[
i
],
op
[
i
],
true
);
}
}
...
@@ -1438,11 +1438,11 @@ TEST(columnTest, json_column_logic_op) {
...
@@ -1438,11 +1438,11 @@ TEST(columnTest, json_column_logic_op) {
printf
(
"--------------------json string-- 6.6hello {1, 8, 2, 2, 3, 0, 0, 0, 0}-------------------
\n
"
);
printf
(
"--------------------json string-- 6.6hello {1, 8, 2, 2, 3, 0, 0, 0, 0}-------------------
\n
"
);
key
=
"k9"
;
key
=
"k9"
;
bool
eRes8
[
len
+
len1
]
=
{
true
,
false
,
false
,
false
,
false
,
tru
e
,
false
,
true
,
true
,
false
,
true
,
false
,
true
};
bool
eRes8
[
len
+
len1
]
=
{
false
,
false
,
false
,
false
,
false
,
fals
e
,
false
,
true
,
true
,
false
,
true
,
false
,
true
};
for
(
int
i
=
0
;
i
<
len
;
i
++
){
for
(
int
i
=
0
;
i
<
len
;
i
++
){
makeCalculate
(
row
,
key
,
TSDB_DATA_TYPE_INT
,
&
input
[
i
],
eRes8
[
i
],
op
[
i
],
false
);
makeCalculate
(
row
,
key
,
TSDB_DATA_TYPE_INT
,
&
input
[
i
],
eRes8
[
i
],
op
[
i
],
false
);
}
}
bool
eRes_8
[
len0
]
=
{
false
,
true
,
true
,
true
,
false
,
tru
e
};
bool
eRes_8
[
len0
]
=
{
false
,
false
,
false
,
false
,
false
,
fals
e
};
for
(
int
i
=
0
;
i
<
len0
;
i
++
)
{
for
(
int
i
=
0
;
i
<
len0
;
i
++
)
{
makeCalculate
(
row
,
key
,
TSDB_DATA_TYPE_INT
,
&
input
[
i
],
eRes_8
[
i
],
op
[
i
],
true
);
makeCalculate
(
row
,
key
,
TSDB_DATA_TYPE_INT
,
&
input
[
i
],
eRes_8
[
i
],
op
[
i
],
true
);
}
}
...
...
tests/system-test/2-query/json_tag.py
浏览文件 @
3ca28608
...
@@ -509,7 +509,7 @@ class TDTestCase:
...
@@ -509,7 +509,7 @@ class TDTestCase:
tdSql
.
checkData
(
0
,
0
,
5.3
)
tdSql
.
checkData
(
0
,
0
,
5.3
)
# tdSql.query("select twa(dataint) from jsons1 where jtag is not null")
# tdSql.query("select twa(dataint) from jsons1 where jtag is not null")
# tdSql.checkData(0, 0, 36)
# tdSql.checkData(0, 0, 36)
tdSql
.
error
(
"select irate(dataint) from jsons1 where jtag is not null"
)
#
tdSql.error("select irate(dataint) from jsons1 where jtag is not null")
tdSql
.
query
(
"select sum(dataint) from jsons1 where jtag->'tag1' is not null"
)
tdSql
.
query
(
"select sum(dataint) from jsons1 where jtag->'tag1' is not null"
)
tdSql
.
checkData
(
0
,
0
,
45
)
tdSql
.
checkData
(
0
,
0
,
45
)
tdSql
.
query
(
"select stddev(dataint) from jsons1 where jtag->'tag1'>1"
)
tdSql
.
query
(
"select stddev(dataint) from jsons1 where jtag->'tag1'>1"
)
...
...
tests/system-test/simpletest.bat
浏览文件 @
3ca28608
...
@@ -4,8 +4,8 @@
...
@@ -4,8 +4,8 @@
python3
.\test.py
-f
0
-others
\taosShellNetChk.py
python3
.\test.py
-f
0
-others
\taosShellNetChk.py
python3
.\test.py
-f
0
-others
\telemetry.py
python3
.\test.py
-f
0
-others
\telemetry.py
python3
.\test.py
-f
0
-others
\taosdMonitor.py
python3
.\test.py
-f
0
-others
\taosdMonitor.py
python3
.\test.py
-f
0
-others
\udfTest.py
@REM
python3 .\test.py -f 0-others\udfTest.py
python3
.\test.py
-f
0
-others
\udf_create.py
@REM
python3 .\test.py -f 0-others\udf_create.py
@REM python3 .\test.py -f 0-others\udf_restart_taosd.py
@REM python3 .\test.py -f 0-others\udf_restart_taosd.py
@REM python3 .\test.py -f 0-others\cachelast.py
@REM python3 .\test.py -f 0-others\cachelast.py
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录