diff options
Diffstat (limited to 'connectivity/source/drivers/kab/KStatement.cxx')
-rw-r--r-- | connectivity/source/drivers/kab/KStatement.cxx | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/connectivity/source/drivers/kab/KStatement.cxx b/connectivity/source/drivers/kab/KStatement.cxx index 72d840132c..51a2851a92 100644 --- a/connectivity/source/drivers/kab/KStatement.cxx +++ b/connectivity/source/drivers/kab/KStatement.cxx @@ -185,12 +185,13 @@ KabCondition *KabCommonStatement::analyseWhereClause(const OSQLParseNode *pParse } } } - else if (pParseNode->count() == 4) + else if (SQL_ISRULE(pParseNode, test_for_null) || SQL_ISRULE(pParseNode, like_predicate)) { - const OSQLParseNode *pLeft = pParseNode->getChild(0), - *pMiddleLeft = pParseNode->getChild(1), - *pMiddleRight = pParseNode->getChild(2), - *pRight = pParseNode->getChild(3); + const OSQLParseNode *pLeft = pParseNode->getChild(0); + const OSQLParseNode* pPart2 = pParseNode->getChild(1); + const OSQLParseNode *pMiddleLeft = pPart2->getChild(0), + *pMiddleRight = pPart2->getChild(1), + *pRight = pPart2->getChild(2); if (SQL_ISRULE(pParseNode, test_for_null)) { |