[Libreoffice-commits] core.git: Branch 'libreoffice-4-0' - connectivity/source

Lionel Elie Mamane lionel at mamane.lu
Tue Jul 9 23:07:57 PDT 2013


 connectivity/source/parse/sqliterator.cxx |    1 +
 1 file changed, 1 insertion(+)

New commits:
commit 75f59b8f79f31af1ffe1fee42d093ae9269485c3
Author: Lionel Elie Mamane <lionel at mamane.lu>
Date:   Wed Jul 10 00:50:11 2013 +0200

    fdo#58644 fix handling of subqueries
    
    don't remove parentheses around subqueries
    (without the parentheses, it is not valid SQL)
    
    Change-Id: I4e9c55cea0276f10b0f97e31bc329949aba5b989
    Reviewed-on: https://gerrit.libreoffice.org/4795
    Reviewed-by: David Tardon <dtardon at redhat.com>
    Tested-by: David Tardon <dtardon at redhat.com>

diff --git a/connectivity/source/parse/sqliterator.cxx b/connectivity/source/parse/sqliterator.cxx
index d2a63e2..cb17652 100644
--- a/connectivity/source/parse/sqliterator.cxx
+++ b/connectivity/source/parse/sqliterator.cxx
@@ -967,6 +967,7 @@ bool OSQLParseTreeIterator::traverseSelectColumnNames(const OSQLParseNode* pSele
                 sal_Bool bFkt(sal_False);
                 pColumnRef = pColumnRef->getChild(0);
                 if (
+                        pColumnRef->getKnownRuleID() != OSQLParseNode::subquery &&
                         pColumnRef->count() == 3 &&
                         SQL_ISPUNCTUATION(pColumnRef->getChild(0),"(") &&
                         SQL_ISPUNCTUATION(pColumnRef->getChild(2),")")


More information about the Libreoffice-commits mailing list