[Libreoffice-commits] core.git: Branch 'libreoffice-4-3' - connectivity/source dbaccess/qa dbaccess/source dbaccess/uiconfig

Julien Nabet serval2412 at yahoo.fr
Sat Oct 11 04:31:17 PDT 2014


 connectivity/source/commontools/DateConversion.cxx          |    6 +++---
 connectivity/source/parse/sqlbison.y                        |    8 ++++++++
 dbaccess/qa/complex/dbaccess/SingleSelectQueryComposer.java |    2 +-
 dbaccess/source/ui/querydesign/QueryDesignView.cxx          |    2 +-
 dbaccess/uiconfig/ui/specialsettingspage.ui                 |    2 +-
 5 files changed, 14 insertions(+), 6 deletions(-)

New commits:
commit 9398fe153ae1a7a26d53424b98c2e8190f236890
Author: Julien Nabet <serval2412 at yahoo.fr>
Date:   Sun Oct 5 21:14:46 2014 +0200

    fdo#84073: change ODBC/JDBC escapes to lowercase
    
    Change-Id: I19ce3acb9575fbef8273bbd84cb4dc322e101ac8
    Reviewed-on: https://gerrit.libreoffice.org/11885
    Reviewed-by: Julien Nabet <serval2412 at yahoo.fr>
    Reviewed-by: Miklos Vajna <vmiklos at collabora.co.uk>
    Tested-by: Miklos Vajna <vmiklos at collabora.co.uk>

diff --git a/connectivity/source/commontools/DateConversion.cxx b/connectivity/source/commontools/DateConversion.cxx
index 1f63db8..1cab87e 100644
--- a/connectivity/source/commontools/DateConversion.cxx
+++ b/connectivity/source/commontools/DateConversion.cxx
@@ -136,7 +136,7 @@ OUString DBTypeConversion::toSQLString(sal_Int32 eType, const Any& _rVal, bool b
                     if ( bOk )
                     {
                         if (bQuote)
-                            aRet.appendAscii("{TS '");
+                            aRet.appendAscii("{ts '");
                         aRet.append(DBTypeConversion::toDateTimeString(aDateTime));
                         if (bQuote)
                             aRet.appendAscii("'}");
@@ -166,7 +166,7 @@ OUString DBTypeConversion::toSQLString(sal_Int32 eType, const Any& _rVal, bool b
                         bOk = _rVal >>= aDate;
                     OSL_VERIFY_RES( bOk, "DBTypeConversion::toSQLString: _rVal is not date!");
                     if (bQuote)
-                        aRet.appendAscii("{D '");
+                        aRet.appendAscii("{d '");
                     aRet.append(DBTypeConversion::toDateString(aDate));
                     if (bQuote)
                         aRet.appendAscii("'}");
@@ -193,7 +193,7 @@ OUString DBTypeConversion::toSQLString(sal_Int32 eType, const Any& _rVal, bool b
                         bOk = _rVal >>= aTime;
                     OSL_VERIFY_RES( bOk,"DBTypeConversion::toSQLString: _rVal is not time!");
                     if (bQuote)
-                        aRet.appendAscii("{T '");
+                        aRet.appendAscii("{t '");
                     aRet.append(DBTypeConversion::toTimeString(aTime));
                     if (bQuote)
                         aRet.appendAscii("'}");
diff --git a/connectivity/source/parse/sqlbison.y b/connectivity/source/parse/sqlbison.y
index 231c9e1..a5b9f2f 100644
--- a/connectivity/source/parse/sqlbison.y
+++ b/connectivity/source/parse/sqlbison.y
@@ -4638,6 +4638,14 @@ OString OSQLParser::TokenIDToStr(sal_uInt32 nTokenID, const IParseContext* pCont
 		aStr = yytname[YYTRANSLATE(nTokenID)];
 		if(aStr.startsWith("SQL_TOKEN_"))
 			aStr = aStr.copy(10);
+		switch( nTokenID )
+		{
+			case SQL_TOKEN_OJ:
+			case SQL_TOKEN_TS:
+			case SQL_TOKEN_T:
+			case SQL_TOKEN_D:
+				aStr = aStr.toAsciiLowerCase();
+		}
 	}
 	return aStr;
 }
diff --git a/dbaccess/qa/complex/dbaccess/SingleSelectQueryComposer.java b/dbaccess/qa/complex/dbaccess/SingleSelectQueryComposer.java
index fc9a5a6..8d6eec6 100644
--- a/dbaccess/qa/complex/dbaccess/SingleSelectQueryComposer.java
+++ b/dbaccess/qa/complex/dbaccess/SingleSelectQueryComposer.java
@@ -51,7 +51,7 @@ public class SingleSelectQueryComposer extends CRMBasedTestCase
             + " OR ( \"ID\" = 3 AND \"Postal\" = '6' AND \"Address\" = '7' )"
             + " OR ( \"Address\" = '8' )"
             + " OR ( \"Postal\" = '9' )"
-            + " OR ( NOW( ) = {D '2010-01-01' } )";
+            + " OR ( NOW( ) = {d '2010-01-01' } )";
     private final static String INNERPRODUCTSQUERY = "products (inner)";
 
 
diff --git a/dbaccess/source/ui/querydesign/QueryDesignView.cxx b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
index 1bfb73c..33bab8f 100644
--- a/dbaccess/source/ui/querydesign/QueryDesignView.cxx
+++ b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
@@ -1073,7 +1073,7 @@ namespace
                                     {
                                         // create outer join
                                         if ( bUseEscape )
-                                            aStr += "{ OJ ";
+                                            aStr += "{ oj ";
                                         aStr += aJoin;
                                         if ( bUseEscape )
                                             aStr += " }";
diff --git a/dbaccess/uiconfig/ui/specialsettingspage.ui b/dbaccess/uiconfig/ui/specialsettingspage.ui
index 3574615..0072f8c 100644
--- a/dbaccess/uiconfig/ui/specialsettingspage.ui
+++ b/dbaccess/uiconfig/ui/specialsettingspage.ui
@@ -76,7 +76,7 @@
             </child>
             <child>
               <object class="GtkCheckButton" id="useoj">
-                <property name="label" translatable="yes">Use Outer Join syntax '{OJ }'</property>
+                <property name="label" translatable="yes">Use Outer Join syntax '{oj }'</property>
                 <property name="visible">True</property>
                 <property name="can_focus">True</property>
                 <property name="receives_default">False</property>


More information about the Libreoffice-commits mailing list