提交 7c008851 编写于 作者: Y yihaoDeng

TD-2850

上级 c37a1185
......@@ -5427,6 +5427,7 @@ int32_t validateColumnName(char* name) {
if (token.type == TK_STRING) {
strdequote(token.z);
strntolower(token.z, token.z, token.n);
token.n = (uint32_t)strtrim(token.z);
int32_t k = tSQLGetToken(token.z, &token.type);
......
......@@ -1420,9 +1420,11 @@ int32_t tscValidateName(SStrToken* pToken) {
char* sep = strnchr(pToken->z, TS_PATH_DELIMITER[0], pToken->n, true);
if (sep == NULL) { // single part
if (pToken->type == TK_STRING) {
strdequote(pToken->z);
strntolower(pToken->z, pToken->z, pToken->n);
pToken->n = (uint32_t)strtrim(pToken->z);
int len = tSQLGetToken(pToken->z, &pToken->type);
// single token, validate it
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册