opti:[TD-28118] raw block data for tmq
This commit is contained in:
parent
4227340d9e
commit
366de880a8
|
@ -662,6 +662,7 @@ int rawBlockBindData(SQuery* query, STableMeta* pTableMeta, void* data, SVCreate
|
||||||
char* p = (char*)data;
|
char* p = (char*)data;
|
||||||
// | version | total length | total rows | total columns | flag seg| block group id | column schema | each column
|
// | version | total length | total rows | total columns | flag seg| block group id | column schema | each column
|
||||||
// length |
|
// length |
|
||||||
|
int32_t version = *(int32_t*)data;
|
||||||
p += sizeof(int32_t);
|
p += sizeof(int32_t);
|
||||||
p += sizeof(int32_t);
|
p += sizeof(int32_t);
|
||||||
|
|
||||||
|
@ -717,7 +718,7 @@ int rawBlockBindData(SQuery* query, STableMeta* pTableMeta, void* data, SVCreate
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
fields += sizeof(int8_t) + sizeof(int32_t);
|
fields += sizeof(int8_t) + sizeof(int32_t);
|
||||||
if (needChangeLength) {
|
if (needChangeLength && version == 1) {
|
||||||
pStart += htonl(colLength[j]);
|
pStart += htonl(colLength[j]);
|
||||||
} else {
|
} else {
|
||||||
pStart += colLength[j];
|
pStart += colLength[j];
|
||||||
|
@ -748,7 +749,7 @@ int rawBlockBindData(SQuery* query, STableMeta* pTableMeta, void* data, SVCreate
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
fields += sizeof(int8_t) + sizeof(int32_t);
|
fields += sizeof(int8_t) + sizeof(int32_t);
|
||||||
if (needChangeLength) {
|
if (needChangeLength && version == 1) {
|
||||||
pStart += htonl(colLength[i]);
|
pStart += htonl(colLength[i]);
|
||||||
} else {
|
} else {
|
||||||
pStart += colLength[i];
|
pStart += colLength[i];
|
||||||
|
|
Loading…
Reference in New Issue