diff --git a/source/client/src/clientTmq.c b/source/client/src/clientTmq.c index 6642e716e600cd07437bbb9dca6a834e4679e64b..16a4f55840bc58170a983f74774cf6418441f29a 100644 --- a/source/client/src/clientTmq.c +++ b/source/client/src/clientTmq.c @@ -373,9 +373,6 @@ int32_t tmq_list_append(tmq_list_t* list, const char* src) { SArray* container = &list->container; if (src == NULL || src[0] == 0) return -1; char* topic = taosStrdup(src); - if (topic[0] != '`') { - strtolower(topic, src); - } if (taosArrayPush(container, &topic) == NULL) return -1; return 0; } diff --git a/tests/system-test/7-tmq/stbTagFilter-1ctb.py b/tests/system-test/7-tmq/stbTagFilter-1ctb.py index 7ee5fce5a81ffb50341a61497f5616b03040d998..1867dc54cb3744077f477f976f88edf59f744dc3 100644 --- a/tests/system-test/7-tmq/stbTagFilter-1ctb.py +++ b/tests/system-test/7-tmq/stbTagFilter-1ctb.py @@ -111,7 +111,7 @@ class TDTestCase: topicFromStb1 = 'topic_UpperCase_stb1' # queryString = "select ts, c1, c2 from %s.%s where t4 == 'shanghai' or t4 == 'changsha'"%(paraDict['dbName'], paraDict['stbName']) queryString = "select ts, c1, c2, t4 from %s.%s where t4 == 'shanghai' or t4 == 'changsha'"%(paraDict['dbName'], paraDict['stbName']) - sqlString = "create topic %s as %s" %(topicFromStb1, queryString) + sqlString = "create topic `%s` as %s" %(topicFromStb1, queryString) tdLog.info("create topic sql: %s"%sqlString) tdSql.execute(sqlString) @@ -148,7 +148,7 @@ class TDTestCase: tmqCom.checkFileContent(consumerId, queryString) - tdSql.query("drop topic %s"%topicFromStb1) + tdSql.query("drop topic `%s`"%topicFromStb1) tdLog.printNoPrefix("======== test case 1 end ...... ") def tmqCase2(self): @@ -196,7 +196,7 @@ class TDTestCase: topicFromStb1 = 'topic_UpperCase_stb1' queryString = "select ts, c1, c2 from %s.%s where t4 == 'shanghai' or t4 == 'changsha'"%(paraDict['dbName'], paraDict['stbName']) # queryString = "select ts, c1, c2, t4 from %s.%s where t4 == 'shanghai' or t4 == 'changsha'"%(paraDict['dbName'], paraDict['stbName']) - sqlString = "create topic %s as %s" %(topicFromStb1, queryString) + sqlString = "create topic `%s` as %s" %(topicFromStb1, queryString) tdLog.info("create topic sql: %s"%sqlString) tdSql.execute(sqlString) @@ -242,7 +242,7 @@ class TDTestCase: # tmqCom.checkFileContent(consumerId, queryString) - tdSql.query("drop topic %s"%topicFromStb1) + tdSql.query("drop topic `%s`"%topicFromStb1) tdLog.printNoPrefix("======== test case 2 end ...... ") diff --git a/tests/system-test/7-tmq/stbTagFilter-multiCtb.py b/tests/system-test/7-tmq/stbTagFilter-multiCtb.py index 71b7fdef5d6a2fc072b7a21ef4205ea7a651bce2..67cc60d196bfd31f75e71978145f58ac40b698c7 100644 --- a/tests/system-test/7-tmq/stbTagFilter-multiCtb.py +++ b/tests/system-test/7-tmq/stbTagFilter-multiCtb.py @@ -111,7 +111,7 @@ class TDTestCase: topicFromStb1 = 'topic_UpperCase_stb1' queryString = "select ts, c1, c2 from %s.%s where t4 == 'beijing' or t4 == 'changsha'"%(paraDict['dbName'], paraDict['stbName']) # queryString = "select ts, c1, c2, t4 from %s.%s where t4 == 'beijing' or t4 == 'changsha'"%(paraDict['dbName'], paraDict['stbName']) - sqlString = "create topic %s as %s" %(topicFromStb1, queryString) + sqlString = "create topic `%s` as %s" %(topicFromStb1, queryString) tdLog.info("create topic sql: %s"%sqlString) tdSql.execute(sqlString) @@ -148,7 +148,7 @@ class TDTestCase: # tmqCom.checkFileContent(consumerId, queryString) - tdSql.query("drop topic %s"%topicFromStb1) + tdSql.query("drop topic `%s`"%topicFromStb1) tdLog.printNoPrefix("======== test case 1 end ...... ") def tmqCase2(self): @@ -196,7 +196,7 @@ class TDTestCase: topicFromStb1 = 'topic_UpperCase_stb1' # queryString = "select ts, c1, c2 from %s.%s where t4 == 'beijing' or t4 == 'changsha'"%(paraDict['dbName'], paraDict['stbName']) queryString = "select ts, c1, c2, t4 from %s.%s where t4 == 'beijing' or t4 == 'changsha'"%(paraDict['dbName'], paraDict['stbName']) - sqlString = "create topic %s as %s" %(topicFromStb1, queryString) + sqlString = "create topic `%s` as %s" %(topicFromStb1, queryString) tdLog.info("create topic sql: %s"%sqlString) tdSql.execute(sqlString) @@ -244,7 +244,7 @@ class TDTestCase: # tmqCom.checkFileContent(consumerId, queryString) - tdSql.query("drop topic %s"%topicFromStb1) + tdSql.query("drop topic `%s`"%topicFromStb1) tdLog.printNoPrefix("======== test case 2 end ...... ") diff --git a/tests/system-test/7-tmq/tmqDropStb.py b/tests/system-test/7-tmq/tmqDropStb.py index a94747e574cf1dd5b10f875dcf6c6590a3532aca..0b252a733495041464a3504a3bc8d94e54fcf48c 100644 --- a/tests/system-test/7-tmq/tmqDropStb.py +++ b/tests/system-test/7-tmq/tmqDropStb.py @@ -82,7 +82,7 @@ class TDTestCase: tdLog.info("create topics from db") topicName1 = 'UpperCasetopic_%s'%(self.paraDict['dbName']) - tdSql.execute("create topic %s as database %s" %(topicName1, self.paraDict['dbName'])) + tdSql.execute("create topic `%s` as database %s" %(topicName1, self.paraDict['dbName'])) topicList = topicName1 + ',' +topicName1 keyList = '%s,%s,%s,%s'%(self.groupId,self.autoCommit,self.autoCommitInterval,self.autoOffset) @@ -113,7 +113,7 @@ class TDTestCase: tdLog.exit("tmq consume rows error!") time.sleep(10) - tdSql.query("drop topic %s"%topicName1) + tdSql.query("drop topic `%s`"%topicName1) tdLog.printNoPrefix("======== test case 1 end ...... ")