You've already forked mariadb-columnstore-engine
mirror of
https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
synced 2025-08-08 14:22:09 +03:00
MCOL-1246 Make matching SQL-92 compliant(ish)
SQL-92 basically specifies for a NOPAD collation that only space should be ignored for matches. Tabs and other whitespace are handled differently. We don't fully support collations yet so we assume the defaults.
This commit is contained in:
@@ -167,7 +167,7 @@ void PrimitiveProcessor::p_TokenByScan(const TokenByScanRequestHeader *h,
|
||||
if (eqFilter) {
|
||||
// MCOL-1246 Trim whitespace before match
|
||||
string strData(sig, siglen);
|
||||
boost::trim_right(strData);
|
||||
boost::trim_right_if(strData, boost::is_any_if(" "));
|
||||
bool gotIt = eqFilter->find(strData) != eqFilter->end();
|
||||
if ((h->COP1 == COMPARE_EQ && gotIt) || (h->COP1 == COMPARE_NE &&
|
||||
!gotIt))
|
||||
@@ -775,7 +775,7 @@ void PrimitiveProcessor::p_Dictionary(const DictInput *in, vector<uint8_t> *out,
|
||||
if (eqFilter) {
|
||||
// MCOL-1246 Trim whitespace before match
|
||||
string strData((char*)sigptr.data, sigptr.len);
|
||||
boost::trim_right(strData);
|
||||
boost::trim_right_if(strData, boost::is_any_of(" "));
|
||||
bool gotIt = eqFilter->find(strData) != eqFilter->end();
|
||||
if ((gotIt && eqOp == COMPARE_EQ) || (!gotIt && eqOp == COMPARE_NE))
|
||||
goto store;
|
||||
|
Reference in New Issue
Block a user