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

MCOL-641 1. Templatized convertValueNum() function.

2. Allocate int128_t buffers in batchprimitiveprocessor if
a query involves wide decimal columns.
This commit is contained in:
Gagan Goel
2020-03-10 19:41:25 -04:00
committed by Roman Nozdrin
parent 9b714274db
commit 62d0c82d75
23 changed files with 235 additions and 105 deletions

View File

@ -18,6 +18,7 @@
#ifndef UTILS_COLWIDTH_H
#define UTILS_COLWIDTH_H
#include "calpontsystemcatalog.h"
#include "branchpred.h"
namespace utils
@ -35,6 +36,13 @@ namespace utils
return width <= MAXLEGACYWIDTH;
}
inline bool isWideDecimalType(const execplan::CalpontSystemCatalog::ColType& ct)
{
return ((ct.colDataType == execplan::CalpontSystemCatalog::DECIMAL ||
ct.colDataType == execplan::CalpontSystemCatalog::UDECIMAL) &&
ct.colWidth == MAXCOLUMNWIDTH);
}
/** @brief Map a DECIMAL precision to data width in bytes */
inline uint8_t widthByPrecision(unsigned p)
{