diff options
author | Ocke Janssen <oj@openoffice.org> | 2009-10-23 05:11:59 +0000 |
---|---|---|
committer | Ocke Janssen <oj@openoffice.org> | 2009-10-23 05:11:59 +0000 |
commit | bef859a2c83b7e96f92953e313af623ee8d65b26 (patch) | |
tree | 40223f263be71e0332b3c209d8a881e0128cdfff | |
parent | f0de84a9ceba2a0f916e3c464637b13ad2f17aef (diff) |
#i105959# handle parameter like column_ref
-rw-r--r-- | dbaccess/source/ui/querydesign/QueryDesignView.cxx | 24 |
1 files changed, 23 insertions, 1 deletions
diff --git a/dbaccess/source/ui/querydesign/QueryDesignView.cxx b/dbaccess/source/ui/querydesign/QueryDesignView.cxx index 2c926e9af..185ff52ef 100644 --- a/dbaccess/source/ui/querydesign/QueryDesignView.cxx +++ b/dbaccess/source/ui/querydesign/QueryDesignView.cxx @@ -1579,10 +1579,32 @@ namespace _pSelectionBrw->AddCondition(aDragLeft, sCondition, nLevel,bAddOrOnOneLine); } } + else + { + // Funktions-Bedingung parsen + ::rtl::OUString sCondition = ParseCondition(rController,pCondition,sDecimal,aLocale,1); + Reference< XConnection> xConnection = rController.getConnection(); + Reference< XDatabaseMetaData > xMetaData = xConnection->getMetaData(); + // the international doesn't matter I have a string + ::rtl::OUString sName; + pCondition->getChild(0)->parseNodeToPredicateStr(sName, + xConnection, + rController.getNumberFormatter(), + aLocale, + static_cast<sal_Char>(sDecimal.toChar()), + &rController.getParser().getContext()); + + OTableFieldDescRef aDragLeft = new OTableFieldDesc(); + aDragLeft->SetField(sName); + aDragLeft->SetFunctionType(FKT_OTHER); + + if ( bHaving ) + aDragLeft->SetGroupBy(sal_True); + _pSelectionBrw->AddCondition(aDragLeft, sCondition, nLevel,bAddOrOnOneLine); + } } else if( SQL_ISRULEOR2(pCondition,existence_test,unique_test) ) { - // Funktions-Bedingung parsen ::rtl::OUString aCondition = ParseCondition(rController,pCondition,sDecimal,aLocale,0); |