From 23237a17fd7ef51f7b0324536fbc724a3bed4aec Mon Sep 17 00:00:00 2001 From: slzhou Date: Tue, 13 Sep 2022 10:35:38 +0800 Subject: [PATCH] fix: syntax error when influxdb lines has no fields --- src/client/src/tscParseLineProtocol.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/client/src/tscParseLineProtocol.c b/src/client/src/tscParseLineProtocol.c index a5673378f5..342ad8b761 100644 --- a/src/client/src/tscParseLineProtocol.c +++ b/src/client/src/tscParseLineProtocol.c @@ -2608,7 +2608,7 @@ int32_t tscParseLine(const char* sql, TAOS_SML_DATA_POINT* smlData, SSmlLinesInf return ret; } tscDebug("SML:0x%"PRIx64" Parse fields finished, num of fields:%d", info->id, smlData->fieldNum); - if (smlData->fieldNum == 0) { + if (smlData->fieldNum <= 1) { tscDebug("SML:0x%"PRIx64" Parse fields error, no field in line", info->id); taosHashCleanup(keyHashTable); return TSDB_CODE_TSC_LINE_SYNTAX_ERROR; -- GitLab