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

MCOL-1428 Fix SUBTIME() with day in WHERE

SUBTIME() with day number used the DATETIME funciton instead of TIME so
got stuck in an endless loop. Now uses the TIME calculations instead.
This commit is contained in:
Andrew Hutchings
2018-06-04 22:03:50 +01:00
parent fd6a2f46a5
commit 92cb6345fb

View File

@ -223,7 +223,14 @@ int64_t Func_add_time::getIntVal(rowgroup::Row& row,
bool& isNull,
CalpontSystemCatalog::ColType& op_ct)
{
return getDatetimeIntVal(row, parm, isNull, op_ct);
if (parm[0]->data()->resultType().colDataType == execplan::CalpontSystemCatalog::TIME)
{
return getTimeIntVal(row, parm, isNull, op_ct);
}
else
{
return getDatetimeIntVal(row, parm, isNull, op_ct);
}
}
string Func_add_time::getStrVal(rowgroup::Row& row,