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

MCOl-3536 Collation phase 2

This commit is contained in:
David Hall
2020-06-15 11:08:59 -05:00
parent 165ae4a6f3
commit d0818f2b4e
6 changed files with 40 additions and 25 deletions

View File

@ -304,7 +304,14 @@ int StringCompare::operator()(IdbCompare* l, Row::Pointer r1, Row::Pointer r2)
if (!cs)
cs = l->rowGroup()->getCharset(fSpec.fIndex);
ret = fSpec.fAsc * cs->strnncollsp(s1, len1, s2, len2);
if (cs->state & MY_CS_BINSORT)
{
ret = fSpec.fAsc * strncmp(s1, s2, max(len1,len2));
}
else
{
ret = fSpec.fAsc * cs->strnncoll(s1, len1, s2, len2);
}
}
return ret;