提交 b32153ea 编写于 作者: wmmhello's avatar wmmhello

TD-6129<feature> fix json encode error

上级 83eef6f5
...@@ -5193,7 +5193,7 @@ char* parseTagDatatoJson(void *p){ ...@@ -5193,7 +5193,7 @@ char* parseTagDatatoJson(void *p){
ASSERT(jsonVal == TSDB_DATA_BINARY_PLACEHOLDER); ASSERT(jsonVal == TSDB_DATA_BINARY_PLACEHOLDER);
continue; continue;
} }
if (j%2 == 0) { // json key if (j%2 != 0) { // json key
memset(tagJsonKey, 0, TSDB_MAX_TAGS_LEN); memset(tagJsonKey, 0, TSDB_MAX_TAGS_LEN);
int32_t length = taosUcs4ToMbs(varDataVal(val), varDataLen(val), tagJsonKey); int32_t length = taosUcs4ToMbs(varDataVal(val), varDataLen(val), tagJsonKey);
if (length == 0) { if (length == 0) {
......
...@@ -3341,7 +3341,7 @@ static void doSetTagValueInParam(void* pTable, int32_t tagColId, tVariant *tag, ...@@ -3341,7 +3341,7 @@ static void doSetTagValueInParam(void* pTable, int32_t tagColId, tVariant *tag,
val = tsdbGetTableName(pTable); val = tsdbGetTableName(pTable);
assert(val != NULL); assert(val != NULL);
} else { } else {
val = tsdbGetTableTagVal(pTable, tagColId, type, bytes); val = tsdbGetTableTagVal(pTable, tagColId, type, bytes); // todo json
} }
if (val == NULL || isNull(val, type)) { if (val == NULL || isNull(val, type)) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册