Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
20a279e6
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看板
未验证
提交
20a279e6
编写于
10月 25, 2022
作者:
S
Shengliang Guan
提交者:
GitHub
10月 25, 2022
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #17605 from taosdata/fix/3.0_bugfix_wxy
fix: wrong permissions of 'show variables' command
上级
90645bd4
2bfaf81e
变更
17
隐藏空白更改
内联
并排
Showing
17 changed file
with
1527 addition
and
1459 deletion
+1527
-1459
include/common/ttokendef.h
include/common/ttokendef.h
+3
-3
include/libs/nodes/cmdnodes.h
include/libs/nodes/cmdnodes.h
+1
-0
source/common/src/systable.c
source/common/src/systable.c
+3
-3
source/libs/nodes/src/nodesUtilFuncs.c
source/libs/nodes/src/nodesUtilFuncs.c
+1
-1
source/libs/parser/inc/parAst.h
source/libs/parser/inc/parAst.h
+1
-1
source/libs/parser/inc/sql.y
source/libs/parser/inc/sql.y
+2
-1
source/libs/parser/src/parAstCreater.c
source/libs/parser/src/parAstCreater.c
+2
-1
source/libs/parser/src/parAstParser.c
source/libs/parser/src/parAstParser.c
+0
-5
source/libs/parser/src/parAuthenticator.c
source/libs/parser/src/parAuthenticator.c
+0
-1
source/libs/parser/src/parTranslater.c
source/libs/parser/src/parTranslater.c
+17
-5
source/libs/parser/src/sql.c
source/libs/parser/src/sql.c
+1434
-1431
source/libs/parser/test/parShowToUse.cpp
source/libs/parser/test/parShowToUse.cpp
+2
-0
source/libs/planner/src/planOptimizer.c
source/libs/planner/src/planOptimizer.c
+27
-3
source/libs/planner/src/planSpliter.c
source/libs/planner/src/planSpliter.c
+15
-0
source/libs/planner/test/planOptimizeTest.cpp
source/libs/planner/test/planOptimizeTest.cpp
+15
-1
source/libs/planner/test/planOtherTest.cpp
source/libs/planner/test/planOtherTest.cpp
+2
-0
tests/script/tsim/user/privilege_sysinfo.sim
tests/script/tsim/user/privilege_sysinfo.sim
+2
-3
未找到文件。
include/common/ttokendef.h
浏览文件 @
20a279e6
...
...
@@ -164,9 +164,9 @@
#define TK_SCORES 146
#define TK_TOPICS 147
#define TK_VARIABLES 148
#define TK_
BNODES
149
#define TK_
S
NODES 150
#define TK_
CLUSTER
151
#define TK_
CLUSTER
149
#define TK_
B
NODES 150
#define TK_
SNODES
151
#define TK_TRANSACTIONS 152
#define TK_DISTRIBUTED 153
#define TK_CONSUMERS 154
...
...
include/libs/nodes/cmdnodes.h
浏览文件 @
20a279e6
...
...
@@ -274,6 +274,7 @@ typedef struct SShowTableDistributedStmt {
typedef
struct
SShowDnodeVariablesStmt
{
ENodeType
type
;
SNode
*
pDnodeId
;
SNode
*
pLikePattern
;
}
SShowDnodeVariablesStmt
;
typedef
struct
SShowVnodesStmt
{
...
...
source/common/src/systable.c
浏览文件 @
20a279e6
...
...
@@ -230,8 +230,8 @@ static const SSysDbTableSchema transSchema[] = {
};
static
const
SSysDbTableSchema
configSchema
[]
=
{
{.
name
=
"name"
,
.
bytes
=
TSDB_CONFIG_OPTION_LEN
+
VARSTR_HEADER_SIZE
,
.
type
=
TSDB_DATA_TYPE_VARCHAR
,
.
sysInfo
=
tru
e
},
{.
name
=
"value"
,
.
bytes
=
TSDB_CONFIG_VALUE_LEN
+
VARSTR_HEADER_SIZE
,
.
type
=
TSDB_DATA_TYPE_VARCHAR
,
.
sysInfo
=
tru
e
},
{.
name
=
"name"
,
.
bytes
=
TSDB_CONFIG_OPTION_LEN
+
VARSTR_HEADER_SIZE
,
.
type
=
TSDB_DATA_TYPE_VARCHAR
,
.
sysInfo
=
fals
e
},
{.
name
=
"value"
,
.
bytes
=
TSDB_CONFIG_VALUE_LEN
+
VARSTR_HEADER_SIZE
,
.
type
=
TSDB_DATA_TYPE_VARCHAR
,
.
sysInfo
=
fals
e
},
};
static
const
SSysDbTableSchema
variablesSchema
[]
=
{
...
...
@@ -282,7 +282,7 @@ static const SSysTableMeta infosMeta[] = {
{
TSDB_INS_TABLE_USERS
,
userUsersSchema
,
tListLen
(
userUsersSchema
),
false
},
{
TSDB_INS_TABLE_LICENCES
,
grantsSchema
,
tListLen
(
grantsSchema
),
true
},
{
TSDB_INS_TABLE_VGROUPS
,
vgroupsSchema
,
tListLen
(
vgroupsSchema
),
true
},
{
TSDB_INS_TABLE_CONFIGS
,
configSchema
,
tListLen
(
configSchema
),
tru
e
},
{
TSDB_INS_TABLE_CONFIGS
,
configSchema
,
tListLen
(
configSchema
),
fals
e
},
{
TSDB_INS_TABLE_DNODE_VARIABLES
,
variablesSchema
,
tListLen
(
variablesSchema
),
true
},
{
TSDB_INS_TABLE_TOPICS
,
topicSchema
,
tListLen
(
topicSchema
),
false
},
{
TSDB_INS_TABLE_SUBSCRIPTIONS
,
subscriptionSchema
,
tListLen
(
subscriptionSchema
),
false
},
...
...
source/libs/nodes/src/nodesUtilFuncs.c
浏览文件 @
20a279e6
...
...
@@ -203,7 +203,6 @@ int32_t nodesReleaseAllocator(int64_t allocatorId) {
return
taosReleaseRef
(
g_allocatorReqRefPool
,
allocatorId
);
}
int64_t
nodesMakeAllocatorWeakRef
(
int64_t
allocatorId
)
{
if
(
allocatorId
<=
0
)
{
return
0
;
...
...
@@ -936,6 +935,7 @@ void nodesDestroyNode(SNode* pNode) {
}
case
QUERY_NODE_SHOW_DNODE_VARIABLES_STMT
:
nodesDestroyNode
(((
SShowDnodeVariablesStmt
*
)
pNode
)
->
pDnodeId
);
nodesDestroyNode
(((
SShowDnodeVariablesStmt
*
)
pNode
)
->
pLikePattern
);
break
;
case
QUERY_NODE_SHOW_CREATE_DATABASE_STMT
:
taosMemoryFreeClear
(((
SShowCreateDatabaseStmt
*
)
pNode
)
->
pCfg
);
...
...
source/libs/parser/inc/parAst.h
浏览文件 @
20a279e6
...
...
@@ -176,7 +176,7 @@ SNode* createShowStmtWithCond(SAstCreateContext* pCxt, ENodeType type, SNode* pD
SNode
*
createShowCreateDatabaseStmt
(
SAstCreateContext
*
pCxt
,
SToken
*
pDbName
);
SNode
*
createShowCreateTableStmt
(
SAstCreateContext
*
pCxt
,
ENodeType
type
,
SNode
*
pRealTable
);
SNode
*
createShowTableDistributedStmt
(
SAstCreateContext
*
pCxt
,
SNode
*
pRealTable
);
SNode
*
createShowDnodeVariablesStmt
(
SAstCreateContext
*
pCxt
,
SNode
*
pDnodeId
);
SNode
*
createShowDnodeVariablesStmt
(
SAstCreateContext
*
pCxt
,
SNode
*
pDnodeId
,
SNode
*
pLikePattern
);
SNode
*
createShowVnodesStmt
(
SAstCreateContext
*
pCxt
,
SNode
*
pDnodeId
,
SNode
*
pDnodeEndpoint
);
SNode
*
createCreateUserStmt
(
SAstCreateContext
*
pCxt
,
SToken
*
pUserName
,
const
SToken
*
pPassword
,
int8_t
sysinfo
);
SNode
*
createAlterUserStmt
(
SAstCreateContext
*
pCxt
,
SToken
*
pUserName
,
int8_t
alterType
,
const
SToken
*
pVal
);
...
...
source/libs/parser/inc/sql.y
浏览文件 @
20a279e6
...
...
@@ -410,8 +410,9 @@ cmd ::= SHOW QUERIES.
cmd ::= SHOW SCORES. { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_SCORES_STMT); }
cmd ::= SHOW TOPICS. { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_TOPICS_STMT); }
cmd ::= SHOW VARIABLES. { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_VARIABLES_STMT); }
cmd ::= SHOW CLUSTER VARIABLES. { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_VARIABLES_STMT); }
cmd ::= SHOW LOCAL VARIABLES. { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_LOCAL_VARIABLES_STMT); }
cmd ::= SHOW DNODE NK_INTEGER(A) VARIABLES
. { pCxt->pRootNode = createShowDnodeVariablesStmt(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &A)
); }
cmd ::= SHOW DNODE NK_INTEGER(A) VARIABLES
like_pattern_opt(B). { pCxt->pRootNode = createShowDnodeVariablesStmt(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &A), B
); }
cmd ::= SHOW BNODES. { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_BNODES_STMT); }
cmd ::= SHOW SNODES. { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_SNODES_STMT); }
cmd ::= SHOW CLUSTER. { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_CLUSTER_STMT); }
...
...
source/libs/parser/src/parAstCreater.c
浏览文件 @
20a279e6
...
...
@@ -1372,11 +1372,12 @@ SNode* createShowTableDistributedStmt(SAstCreateContext* pCxt, SNode* pRealTable
return
(
SNode
*
)
pStmt
;
}
SNode
*
createShowDnodeVariablesStmt
(
SAstCreateContext
*
pCxt
,
SNode
*
pDnodeId
)
{
SNode
*
createShowDnodeVariablesStmt
(
SAstCreateContext
*
pCxt
,
SNode
*
pDnodeId
,
SNode
*
pLikePattern
)
{
CHECK_PARSER_STATUS
(
pCxt
);
SShowDnodeVariablesStmt
*
pStmt
=
(
SShowDnodeVariablesStmt
*
)
nodesMakeNode
(
QUERY_NODE_SHOW_DNODE_VARIABLES_STMT
);
CHECK_OUT_OF_MEM
(
pStmt
);
pStmt
->
pDnodeId
=
pDnodeId
;
pStmt
->
pLikePattern
=
pLikePattern
;
return
(
SNode
*
)
pStmt
;
}
...
...
source/libs/parser/src/parAstParser.c
浏览文件 @
20a279e6
...
...
@@ -484,11 +484,6 @@ static int32_t collectMetaKeyFromShowQueries(SCollectMetaKeyCxt* pCxt, SShowStmt
pCxt
->
pMetaCache
);
}
static
int32_t
collectMetaKeyFromShowConfigs
(
SCollectMetaKeyCxt
*
pCxt
,
SShowStmt
*
pStmt
)
{
return
reserveTableMetaInCache
(
pCxt
->
pParseCxt
->
acctId
,
TSDB_INFORMATION_SCHEMA_DB
,
TSDB_INS_TABLE_CONFIGS
,
pCxt
->
pMetaCache
);
}
static
int32_t
collectMetaKeyFromShowVariables
(
SCollectMetaKeyCxt
*
pCxt
,
SShowStmt
*
pStmt
)
{
return
reserveTableMetaInCache
(
pCxt
->
pParseCxt
->
acctId
,
TSDB_INFORMATION_SCHEMA_DB
,
TSDB_INS_TABLE_CONFIGS
,
pCxt
->
pMetaCache
);
...
...
source/libs/parser/src/parAuthenticator.c
浏览文件 @
20a279e6
...
...
@@ -125,7 +125,6 @@ static int32_t authQuery(SAuthCxt* pCxt, SNode* pStmt) {
case
QUERY_NODE_SHOW_CLUSTER_STMT
:
case
QUERY_NODE_SHOW_LICENCES_STMT
:
case
QUERY_NODE_SHOW_VGROUPS_STMT
:
case
QUERY_NODE_SHOW_VARIABLES_STMT
:
case
QUERY_NODE_SHOW_CREATE_DATABASE_STMT
:
case
QUERY_NODE_SHOW_TABLE_DISTRIBUTED_STMT
:
case
QUERY_NODE_SHOW_VNODES_STMT
:
...
...
source/libs/parser/src/parTranslater.c
浏览文件 @
20a279e6
...
...
@@ -6259,16 +6259,28 @@ static int32_t rewriteShowStableTags(STranslateContext* pCxt, SQuery* pQuery) {
}
static
int32_t
rewriteShowDnodeVariables
(
STranslateContext
*
pCxt
,
SQuery
*
pQuery
)
{
SSelectStmt
*
pStmt
=
NULL
;
int32_t
code
=
createSelectStmtForShow
(
nodeType
(
pQuery
->
pRoot
),
&
pStmt
);
SShowDnodeVariablesStmt
*
pStmt
=
(
SShowDnodeVariablesStmt
*
)
pQuery
->
pRoot
;
SNode
*
pDnodeCond
=
NULL
;
SNode
*
pLikeCond
=
NULL
;
SSelectStmt
*
pSelect
=
NULL
;
int32_t
code
=
createSelectStmtForShow
(
nodeType
(
pQuery
->
pRoot
),
&
pSelect
);
if
(
TSDB_CODE_SUCCESS
==
code
)
{
code
=
createOperatorNode
(
OP_TYPE_EQUAL
,
"dnode_id"
,
pStmt
->
pDnodeId
,
&
pDnodeCond
);
}
if
(
TSDB_CODE_SUCCESS
==
code
)
{
code
=
createOperatorNode
(
OP_TYPE_LIKE
,
"name"
,
pStmt
->
pLikePattern
,
&
pLikeCond
);
}
if
(
TSDB_CODE_SUCCESS
==
code
)
{
code
=
createOperatorNode
(
OP_TYPE_EQUAL
,
"dnode_id"
,
((
SShowDnodeVariablesStmt
*
)
pQuery
->
pRoot
)
->
pDnodeId
,
&
pStmt
->
pWhere
);
if
(
NULL
!=
pLikeCond
)
{
code
=
createLogicCondNode
(
pDnodeCond
,
pLikeCond
,
&
pSelect
->
pWhere
);
}
else
{
pSelect
->
pWhere
=
pDnodeCond
;
}
}
if
(
TSDB_CODE_SUCCESS
==
code
)
{
pQuery
->
showRewrite
=
true
;
nodesDestroyNode
(
pQuery
->
pRoot
);
pQuery
->
pRoot
=
(
SNode
*
)
pS
tm
t
;
pQuery
->
pRoot
=
(
SNode
*
)
pS
elec
t
;
}
return
code
;
}
...
...
source/libs/parser/src/sql.c
浏览文件 @
20a279e6
因为 它太大了无法显示 source diff 。你可以改为
查看blob
。
source/libs/parser/test/parShowToUse.cpp
浏览文件 @
20a279e6
...
...
@@ -100,6 +100,8 @@ TEST_F(ParserShowToUseTest, showDnodeVariables) {
useDb
(
"root"
,
"test"
);
run
(
"SHOW DNODE 1 VARIABLES"
);
run
(
"SHOW DNODE 1 VARIABLES LIKE '%debug%'"
);
}
TEST_F
(
ParserShowToUseTest
,
showFunctions
)
{
...
...
source/libs/planner/src/planOptimizer.c
浏览文件 @
20a279e6
...
...
@@ -2365,7 +2365,7 @@ static int32_t mergeProjectsOptimize(SOptimizeContext* pCxt, SLogicSubplan* pLog
return
mergeProjectsOptimizeImpl
(
pCxt
,
pLogicSubplan
,
pProjectNode
);
}
static
bool
tagScan
May
BeOptimized
(
SLogicNode
*
pNode
)
{
static
bool
tagScan
OptShould
BeOptimized
(
SLogicNode
*
pNode
)
{
if
(
QUERY_NODE_LOGIC_PLAN_SCAN
!=
nodeType
(
pNode
)
||
(
SCAN_TYPE_TAG
==
((
SScanLogicNode
*
)
pNode
)
->
scanType
))
{
return
false
;
}
...
...
@@ -2397,7 +2397,7 @@ static bool tagScanMayBeOptimized(SLogicNode* pNode) {
}
static
int32_t
tagScanOptimize
(
SOptimizeContext
*
pCxt
,
SLogicSubplan
*
pLogicSubplan
)
{
SScanLogicNode
*
pScanNode
=
(
SScanLogicNode
*
)
optFindPossibleNode
(
pLogicSubplan
->
pNode
,
tagScan
May
BeOptimized
);
SScanLogicNode
*
pScanNode
=
(
SScanLogicNode
*
)
optFindPossibleNode
(
pLogicSubplan
->
pNode
,
tagScan
OptShould
BeOptimized
);
if
(
NULL
==
pScanNode
)
{
return
TSDB_CODE_SUCCESS
;
}
...
...
@@ -2440,6 +2440,29 @@ static int32_t tagScanOptimize(SOptimizeContext* pCxt, SLogicSubplan* pLogicSubp
return
TSDB_CODE_SUCCESS
;
}
static
bool
pushDownLimitOptShouldBeOptimized
(
SLogicNode
*
pNode
)
{
if
(
NULL
==
pNode
->
pLimit
||
1
!=
LIST_LENGTH
(
pNode
->
pChildren
)
||
QUERY_NODE_LOGIC_PLAN_SCAN
!=
nodeType
(
nodesListGetNode
(
pNode
->
pChildren
,
0
)))
{
return
false
;
}
return
true
;
}
static
int32_t
pushDownLimitOptimize
(
SOptimizeContext
*
pCxt
,
SLogicSubplan
*
pLogicSubplan
)
{
SLogicNode
*
pNode
=
optFindPossibleNode
(
pLogicSubplan
->
pNode
,
pushDownLimitOptShouldBeOptimized
);
if
(
NULL
==
pNode
)
{
return
TSDB_CODE_SUCCESS
;
}
SLogicNode
*
pChild
=
(
SLogicNode
*
)
nodesListGetNode
(
pNode
->
pChildren
,
0
);
nodesDestroyNode
(
pChild
->
pLimit
);
pChild
->
pLimit
=
pNode
->
pLimit
;
pNode
->
pLimit
=
NULL
;
pCxt
->
optimized
=
true
;
return
TSDB_CODE_SUCCESS
;
}
// clang-format off
static
const
SOptimizeRule
optimizeRuleSet
[]
=
{
{.
pName
=
"ScanPath"
,
.
optimizeFunc
=
scanPathOptimize
},
...
...
@@ -2453,7 +2476,8 @@ static const SOptimizeRule optimizeRuleSet[] = {
{.
pName
=
"RewriteTail"
,
.
optimizeFunc
=
rewriteTailOptimize
},
{.
pName
=
"RewriteUnique"
,
.
optimizeFunc
=
rewriteUniqueOptimize
},
{.
pName
=
"LastRowScan"
,
.
optimizeFunc
=
lastRowScanOptimize
},
{.
pName
=
"TagScan"
,
.
optimizeFunc
=
tagScanOptimize
}
{.
pName
=
"TagScan"
,
.
optimizeFunc
=
tagScanOptimize
},
// {.pName = "PushDownLimit", .optimizeFunc = pushDownLimitOptimize}
};
// clang-format on
...
...
source/libs/planner/src/planSpliter.c
浏览文件 @
20a279e6
...
...
@@ -84,6 +84,7 @@ static int32_t splCreateExchangeNode(SSplitContext* pCxt, SLogicNode* pChild, SE
if
(
NULL
==
pExchange
)
{
return
TSDB_CODE_OUT_OF_MEMORY
;
}
pExchange
->
srcStartGroupId
=
pCxt
->
groupId
;
pExchange
->
srcEndGroupId
=
pCxt
->
groupId
;
pExchange
->
node
.
precision
=
pChild
->
precision
;
...
...
@@ -91,6 +92,13 @@ static int32_t splCreateExchangeNode(SSplitContext* pCxt, SLogicNode* pChild, SE
if
(
NULL
==
pExchange
->
node
.
pTargets
)
{
return
TSDB_CODE_OUT_OF_MEMORY
;
}
if
(
NULL
!=
pChild
->
pLimit
)
{
pExchange
->
node
.
pLimit
=
nodesCloneNode
(
pChild
->
pLimit
);
if
(
NULL
==
pExchange
->
node
.
pLimit
)
{
return
TSDB_CODE_OUT_OF_MEMORY
;
}
((
SLimitNode
*
)
pChild
->
pLimit
)
->
offset
=
0
;
}
*
pOutput
=
pExchange
;
return
TSDB_CODE_SUCCESS
;
...
...
@@ -921,6 +929,13 @@ static int32_t stbSplSplitScanNodeWithoutPartTags(SSplitContext* pCxt, SStableSp
if
(
NULL
!=
pInfo
->
pSplitNode
->
pParent
&&
QUERY_NODE_LOGIC_PLAN_PROJECT
==
nodeType
(
pInfo
->
pSplitNode
->
pParent
)
&&
NULL
==
pInfo
->
pSplitNode
->
pParent
->
pLimit
&&
NULL
==
pInfo
->
pSplitNode
->
pParent
->
pSlimit
)
{
pSplitNode
=
pInfo
->
pSplitNode
->
pParent
;
if
(
NULL
!=
pInfo
->
pSplitNode
->
pLimit
)
{
pSplitNode
->
pLimit
=
nodesCloneNode
(
pInfo
->
pSplitNode
->
pLimit
);
if
(
NULL
==
pSplitNode
->
pLimit
)
{
return
TSDB_CODE_OUT_OF_MEMORY
;
}
((
SLimitNode
*
)
pInfo
->
pSplitNode
->
pLimit
)
->
offset
=
0
;
}
}
int32_t
code
=
splCreateExchangeNodeForSubplan
(
pCxt
,
pInfo
->
pSubplan
,
pSplitNode
,
SUBPLAN_TYPE_MERGE
);
if
(
TSDB_CODE_SUCCESS
==
code
)
{
...
...
source/libs/planner/test/planOptimizeTest.cpp
浏览文件 @
20a279e6
...
...
@@ -95,9 +95,13 @@ TEST_F(PlanOptimizeTest, eliminateProjection) {
useDb
(
"root"
,
"test"
);
run
(
"SELECT c1, sum(c3) FROM t1 GROUP BY c1"
);
run
(
"SELECT c1 FROM t1"
);
run
(
"SELECT * FROM st1"
);
run
(
"SELECT c1 FROM st1s3"
);
// run("select 1-abs(c1) from (select unique(c1) c1 from st1s3) order by 1 nulls first");
}
...
...
@@ -136,4 +140,14 @@ TEST_F(PlanOptimizeTest, tagScan) {
run
(
"select tag1 from st1 group by tag1"
);
run
(
"select distinct tag1 from st1"
);
run
(
"select tag1*tag1 from st1 group by tag1*tag1"
);
}
\ No newline at end of file
}
TEST_F
(
PlanOptimizeTest
,
pushDownLimit
)
{
useDb
(
"root"
,
"test"
);
run
(
"SELECT c1 FROM t1 LIMIT 1"
);
run
(
"SELECT c1 FROM st1 LIMIT 1"
);
run
(
"SELECT c1 FROM st1 LIMIT 20 OFFSET 10"
);
}
source/libs/planner/test/planOtherTest.cpp
浏览文件 @
20a279e6
...
...
@@ -85,6 +85,8 @@ TEST_F(PlanOtherTest, show) {
run
(
"SHOW DNODE 1 VARIABLES"
);
run
(
"SHOW DNODE 1 VARIABLES LIKE '%debug%'"
);
run
(
"SHOW TAGS FROM st1s1"
);
run
(
"SHOW TABLE TAGS FROM st1"
);
...
...
tests/script/tsim/user/privilege_sysinfo.sim
浏览文件 @
20a279e6
...
...
@@ -137,10 +137,9 @@ sql_error show create database d2
sql show create table d2.stb2;
sql show create table d2.ctb2;
sql show create table d2.ntb2;
sql_error show variables;
sql show local variables;
sql_error show dnode 1 variables;
sql
_error
show variables;
sql
show variables;
print =============== check information_schema
...
...
@@ -167,7 +166,7 @@ sql select * from information_schema.ins_subscriptions
sql select * from information_schema.ins_streams
sql_error select * from information_schema.ins_grants
sql_error select * from information_schema.ins_vgroups
sql
_error
select * from information_schema.ins_configs
sql select * from information_schema.ins_configs
sql_error select * from information_schema.ins_dnode_variables
print =============== check performance_schema
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录