fix: search k-way number

This commit is contained in:
slzhou 2023-06-17 22:13:08 +08:00
parent 0a567252f5
commit 577c131360
1 changed files with 4 additions and 0 deletions

View File

@ -2790,6 +2790,10 @@ int32_t startGroupTableMergeScan(SOperatorInfo* pOperator) {
kWay = 256;
} else if (kWay <= 2) {
kWay = 2;
} else {
int i = 2;
while (i * 2 <= kWay) i = i * 2;
kWay = i;
}
pInfo->sortBufSize = pInfo->bufPageSize * (kWay + 1);