提交 5127b9a1 编写于 作者: guanshengliang's avatar guanshengliang

fix bug while alter table

上级 085abd40
...@@ -828,10 +828,10 @@ static void mgmtProcessDropSuperTableMsg(SQueuedMsg *pMsg) { ...@@ -828,10 +828,10 @@ static void mgmtProcessDropSuperTableMsg(SQueuedMsg *pMsg) {
} }
static int32_t mgmtFindSuperTableTagIndex(SSuperTableObj *pStable, const char *tagName) { static int32_t mgmtFindSuperTableTagIndex(SSuperTableObj *pStable, const char *tagName) {
for (int32_t i = 0; i < pStable->numOfTags; i++) { SSchema *schema = (SSchema *) pStable->schema;
SSchema *schema = (SSchema *)(pStable->schema + (pStable->numOfColumns + i) * sizeof(SSchema)); for (int32_t tag = 0; tag < pStable->numOfTags; tag++) {
if (strcasecmp(tagName, schema->name) == 0) { if (strcasecmp(schema[pStable->numOfColumns + tag].name, tagName) == 0) {
return i; return tag;
} }
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册