fix(query): set correct group table size.

This commit is contained in:
Haojun Liao 2023-02-08 14:26:04 +08:00
parent aab31f655c
commit 43cce095d0
1 changed files with 2 additions and 2 deletions

View File

@ -1831,9 +1831,9 @@ int32_t tableListGetGroupList(const STableListInfo* pTableList, int32_t ordinalG
int32_t offset = pTableList->groupOffset[ordinalGroupIndex]; int32_t offset = pTableList->groupOffset[ordinalGroupIndex];
if (ordinalGroupIndex < total - 1) { if (ordinalGroupIndex < total - 1) {
*size = pTableList->groupOffset[offset + 1] - pTableList->groupOffset[offset]; *size = pTableList->groupOffset[ordinalGroupIndex + 1] - offset;
} else { } else {
*size = total - pTableList->groupOffset[offset] - 1; *size = total - offset;
} }
*pKeyInfo = taosArrayGet(pTableList->pTableList, offset); *pKeyInfo = taosArrayGet(pTableList->pTableList, offset);