[Libreoffice-commits] core.git: Branch 'libreoffice-5-3' - connectivity/source

Julien Nabet serval2412 at yahoo.fr
Sun Dec 4 21:55:49 UTC 2016


 connectivity/source/drivers/firebird/ResultSet.cxx |    8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

New commits:
commit d5fc585db2071c57cf9c70f071c8d330ebeca1e4
Author: Julien Nabet <serval2412 at yahoo.fr>
Date:   Sun Dec 4 13:39:47 2016 +0100

    tdf#104227: fix subtypes DECIMAL/NUMERIC in resultset
    
    bt here:
    https://bug-attachments.documentfoundation.org/attachment.cgi?id=129298
    
    See also https://bugs.documentfoundation.org/show_bug.cgi?id=104227#c13 for more details
    
    Change-Id: Ied497cfff2f71e67161d541b90fe48bb3e2456b9
    Reviewed-on: https://gerrit.libreoffice.org/31593
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Tamás Bunth <btomi96 at gmail.com>
    Reviewed-by: Julien Nabet <serval2412 at yahoo.fr>
    (cherry picked from commit 8d2f58a9922ca7352c626db06f9b8d5ca0bbaead)
    Reviewed-on: https://gerrit.libreoffice.org/31598

diff --git a/connectivity/source/drivers/firebird/ResultSet.cxx b/connectivity/source/drivers/firebird/ResultSet.cxx
index f480465..c19207d 100644
--- a/connectivity/source/drivers/firebird/ResultSet.cxx
+++ b/connectivity/source/drivers/firebird/ResultSet.cxx
@@ -455,17 +455,17 @@ ORowSetValue OResultSet::retrieveValue(const sal_Int32 nColumnIndex, const ISC_S
         case SQL_VARYING:
             return getString(nColumnIndex);
         case SQL_SHORT:
-            if(nSqlSubType == 0 || nSqlSubType == 1) //numeric or decimal
+            if(nSqlSubType == 1 || nSqlSubType == 2) //numeric or decimal
                 return getString(nColumnIndex);
             return getShort(nColumnIndex);
         case SQL_LONG:
-            if(nSqlSubType == 0 || nSqlSubType == 1) //numeric or decimal
+            if(nSqlSubType == 1 || nSqlSubType == 2) //numeric or decimal
                 return getString(nColumnIndex);
             return getInt(nColumnIndex);
         case SQL_FLOAT:
             return getFloat(nColumnIndex);
         case SQL_DOUBLE:
-            if(nSqlSubType == 0 || nSqlSubType == 1) //numeric or decimal
+            if(nSqlSubType == 1 || nSqlSubType == 2) //numeric or decimal
                 return getString(nColumnIndex);
             return getDouble(nColumnIndex);
         case SQL_D_FLOAT:
@@ -477,7 +477,7 @@ ORowSetValue OResultSet::retrieveValue(const sal_Int32 nColumnIndex, const ISC_S
         case SQL_TYPE_DATE:
             return getDate(nColumnIndex);
         case SQL_INT64:
-            if(nSqlSubType == 0 || nSqlSubType == 1) //numeric or decimal
+            if(nSqlSubType == 1 || nSqlSubType == 2) //numeric or decimal
                 return getString(nColumnIndex);
             return getLong(nColumnIndex);
         case SQL_BLOB:


More information about the Libreoffice-commits mailing list