From 0dd4433e581e419bad0b8f4ef65e5389faa55ecb Mon Sep 17 00:00:00 2001 From: yihaoDeng Date: Sun, 5 Feb 2023 11:49:45 +0800 Subject: [PATCH] opt index --- source/dnode/vnode/src/meta/metaTable.c | 2 +- source/libs/executor/src/executil.c | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/source/dnode/vnode/src/meta/metaTable.c b/source/dnode/vnode/src/meta/metaTable.c index f95cf171ab..5953157591 100644 --- a/source/dnode/vnode/src/meta/metaTable.c +++ b/source/dnode/vnode/src/meta/metaTable.c @@ -565,7 +565,7 @@ int metaDropIndexFromSTable(SMeta *pMeta, int64_t version, SDropIndexReq *pReq) int32_t colId = -1; for (int i = 0; i < oStbEntry.stbEntry.schemaTag.nCols; i++) { SSchema *schema = oStbEntry.stbEntry.schemaTag.pSchema + i; - if (strncmp(schema->name, pReq->colName, sizeof(pReq->colName))) { + if (0 == strncmp(schema->name, pReq->colName, sizeof(pReq->colName))) { if (IS_IDX_ON(schema)) { pCol = schema; } diff --git a/source/libs/executor/src/executil.c b/source/libs/executor/src/executil.c index 54c913df3b..5b1b4fd4ce 100644 --- a/source/libs/executor/src/executil.c +++ b/source/libs/executor/src/executil.c @@ -1095,6 +1095,8 @@ int32_t getTableList(void* metaHandle, void* pVnode, SScanPhysiNode* pScanNode, if (code != 0 || status == SFLT_NOT_INDEX) { qError("failed to get tableIds from index, reason:%s, suid:%" PRIu64, tstrerror(code), tableUid); code = TDB_CODE_SUCCESS; + } else { + qInfo("succ to get filter result, table num: %d", (int)taosArrayGetSize(res)); } } } -- GitLab