1
0
mirror of https://github.com/mariadb-corporation/mariadb-columnstore-engine.git synced 2025-07-29 08:21:15 +03:00

MCOL-4801 Replace Row methods getStringLength() and getStringPointer() to getConstString()

This commit is contained in:
Alexander Barkov
2021-07-06 21:15:32 +04:00
parent b9bd207d3b
commit 9794f24369
13 changed files with 73 additions and 135 deletions

View File

@ -494,16 +494,19 @@ void WindowFunctionColumn::evaluate(Row& row, bool& isNull)
case 16:
//fallthrough
default:
if (row.equals(CPNULLSTRMARK, fInputIndex))
{
const auto str = row.getConstString(fInputIndex);
if (str.eq(utils::ConstString(CPNULLSTRMARK)))
isNull = true;
else
fResult.strVal = row.getStringField(fInputIndex);
fResult.strVal = str.toString();
// stringColVal is padded with '\0' to colWidth so can't use str.length()
if (strlen(fResult.strVal.c_str()) == 0)
isNull = true;
break;
}
}
if (fResultType.colDataType == CalpontSystemCatalog::STRINT)