未验证 提交 7a896f24 编写于 作者: A Alex Duan 提交者: GitHub

Merge pull request #16243 from taosdata/cases/TS-1788-V26

fix(subscribe): TS-1788-V26 remove strtolower for sql
......@@ -149,7 +149,6 @@ static SSub* tscCreateSubscription(STscObj* pObj, const char* topic, const char*
goto fail;
}
strtolower(pSql->sqlstr, pSql->sqlstr);
pRes->qId = 0;
pRes->numOfRows = 1;
pCmd->resColumnId = TSDB_RES_COL_ID;
......
......@@ -68,8 +68,24 @@ class TDTestCase:
tdSub.consume()
tdSub.checkRows(11)
# TS-1788: Subscribe a case sensitive table
tdLog.info("create a table and insert 10 rows.")
tdSql.execute("create table `T1`(ts timestamp, a int, b int);")
for i in range(0, 10):
tdSql.execute("insert into `T1` values (%d, %d, %d);" % (now + i, i, i))
sqlstr = "select * from `T1`"
topic = "topic1"
now = int(time.time() * 1000)
tdSub.init(self.conn.subscribe(True, topic, sqlstr, 0))
tdSub.consume()
tdSub.checkRows(10)
tdSub.close(True)
def stop(self):
tdSub.close(False)
tdSql.close()
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册