diff options
author | Lionel Elie Mamane <lionel@mamane.lu> | 2015-01-28 21:09:42 +0100 |
---|---|---|
committer | Lionel Elie Mamane <lionel@mamane.lu> | 2015-01-28 21:16:13 +0100 |
commit | b63547c8ea8ac2e198193cba1026e7729c70f43a (patch) | |
tree | feee38102f75be881c1f2597800abf438211f075 /dbaccess/source/ui | |
parent | 063105b4af5518fd8306246ea49326958e435e1a (diff) |
not all OrCriteria have three children
and some contain a column in the second child
Change-Id: Ifd69758336233ed0233120b3315d4f33655fa994
Diffstat (limited to 'dbaccess/source/ui')
-rw-r--r-- | dbaccess/source/ui/querydesign/QueryDesignView.cxx | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/dbaccess/source/ui/querydesign/QueryDesignView.cxx b/dbaccess/source/ui/querydesign/QueryDesignView.cxx index 8acc4115413f..032ca0dfdcce 100644 --- a/dbaccess/source/ui/querydesign/QueryDesignView.cxx +++ b/dbaccess/source/ui/querydesign/QueryDesignView.cxx @@ -1305,10 +1305,12 @@ namespace { bool bRet = true; ::connectivity::OSQLParseNode* pFirstColumnRef = _pFirstColumnRef; - for (int i = 0; i < 3 && bRet; i+=2) + for (size_t i = 0; bRet && i < _pCondition->count() && bRet; ++i) { const ::connectivity::OSQLParseNode* pChild = _pCondition->getChild(i); - if ( SQL_ISRULE(pChild,search_condition) ) + if ( pChild->isToken() ) + continue; + else if ( SQL_ISRULE(pChild,search_condition) ) bRet = CheckOrCriteria(pChild,pFirstColumnRef); else { |