From 905ce2ce8b6d6a41fa129bb0dc8e6c94e9021515 Mon Sep 17 00:00:00 2001 From: Andrew Hutchings Date: Fri, 9 Mar 2018 11:14:33 +0000 Subject: [PATCH] MCOL-1246 Fix for non-DSS step For TEXT columns (and some other scenarios) we don't do a DSS step to scan dictionaries and do it directly in the BPS step instead. This patch applies the previous fix to this case too. --- primitives/linux-port/dictionary.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/primitives/linux-port/dictionary.cpp b/primitives/linux-port/dictionary.cpp index 88d71dc3d..0e6083505 100644 --- a/primitives/linux-port/dictionary.cpp +++ b/primitives/linux-port/dictionary.cpp @@ -773,8 +773,10 @@ void PrimitiveProcessor::p_Dictionary(const DictInput *in, vector *out, filterOffset = sizeof(DictInput) + (in->NVALS * sizeof(PrimToken)); if (eqFilter) { - bool gotIt = (eqFilter->find(string((char *) sigptr.data, sigptr.len)) - != eqFilter->end()); + // MCOL-1246 Trim whitespace before match + string strData((char*)sigptr.data, sigptr.len); + boost::trim_right(strData); + bool gotIt = eqFilter->find(strData) != eqFilter->end(); if ((gotIt && eqOp == COMPARE_EQ) || (!gotIt && eqOp == COMPARE_NE)) goto store; goto no_store;