diff --git a/src/client/src/tscUtil.c b/src/client/src/tscUtil.c index 92f843e3a912245d180cab65e2611417cbb344f0..2be3c3bc33e1aebf109c2e0076e27f096fade3d1 100644 --- a/src/client/src/tscUtil.c +++ b/src/client/src/tscUtil.c @@ -4235,6 +4235,10 @@ void executeQuery(SSqlObj* pSql, SQueryInfo* pQueryInfo) { } return; + } else if (hasMoreClauseToTry(pSql)) { + if (pthread_mutex_init(&pSql->subState.mutex, NULL) != 0) { + goto _error; + } } pSql->cmd.active = pQueryInfo;