1
0
mirror of https://github.com/mariadb-corporation/mariadb-columnstore-engine.git synced 2025-07-30 19:23:07 +03:00

MCOL-698 Fix joiner for LONGTEXT

It turns out not many machines have 32TB of RAM, so lets try not to
allocate that much for a LONGTEXT key join...
This commit is contained in:
Andrew Hutchings
2017-05-04 15:14:27 +01:00
parent 2cbf57c053
commit 00cd7f40c1

View File

@ -112,7 +112,12 @@ TupleJoiner::TupleJoiner(
smallRG.getColTypes()[smallKeyColumns[i]] == CalpontSystemCatalog::VARCHAR
||
smallRG.getColTypes()[smallKeyColumns[i]] == CalpontSystemCatalog::TEXT)
{
keyLength += smallRG.getColumnWidth(smallKeyColumns[i]) + 1; // +1 null char
// MCOL-698: if we don't do this LONGTEXT allocates 32TB RAM
if (keyLength > 65536)
keyLength = 65536;
}
else
keyLength += 8;
// Set bSignedUnsignedJoin if one or more join columns are signed to unsigned compares.