fix(tsdb/read): use correct scheme for mem & imem merging
This commit is contained in:
parent
f1ff5dcec4
commit
8cf8ac84d7
|
@ -3674,8 +3674,9 @@ int32_t doMergeMemIMemRows(TSDBROW* pRow, TSDBROW* piRow, STableBlockScanInfo* p
|
||||||
|
|
||||||
if (ASCENDING_TRAVERSE(pReader->order)) { // ascending order imem --> mem
|
if (ASCENDING_TRAVERSE(pReader->order)) { // ascending order imem --> mem
|
||||||
STSchema* pSchema = doGetSchemaForTSRow(TSDBROW_SVERSION(pRow), pReader, pBlockScanInfo->uid);
|
STSchema* pSchema = doGetSchemaForTSRow(TSDBROW_SVERSION(pRow), pReader, pBlockScanInfo->uid);
|
||||||
|
STSchema* piSchema = doGetSchemaForTSRow(TSDBROW_SVERSION(piRow), pReader, pBlockScanInfo->uid);
|
||||||
|
|
||||||
int32_t code = tsdbRowMergerInit(&merge, piRow, pSchema);
|
int32_t code = tsdbRowMergerInit2(&merge, pSchema, piRow, piSchema);
|
||||||
if (code != TSDB_CODE_SUCCESS) {
|
if (code != TSDB_CODE_SUCCESS) {
|
||||||
return code;
|
return code;
|
||||||
}
|
}
|
||||||
|
@ -4082,7 +4083,7 @@ int32_t tsdbReaderOpen(SVnode* pVnode, SQueryTableDataCond* pCond, void* pTableL
|
||||||
|
|
||||||
pReader->pSchemaMap = tSimpleHashInit(8, taosFastHash);
|
pReader->pSchemaMap = tSimpleHashInit(8, taosFastHash);
|
||||||
if (pReader->pSchemaMap == NULL) {
|
if (pReader->pSchemaMap == NULL) {
|
||||||
tsdbError("failed init schema hash for reader", pReader->idStr);
|
tsdbError("failed init schema hash for reader %s", pReader->idStr);
|
||||||
code = TSDB_CODE_OUT_OF_MEMORY;
|
code = TSDB_CODE_OUT_OF_MEMORY;
|
||||||
goto _err;
|
goto _err;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue