[Libreoffice-commits] core.git: connectivity/source

Julien Nabet (via logerrit) logerrit at kemper.freedesktop.org
Sun Dec 6 11:50:43 UTC 2020


 connectivity/source/drivers/firebird/DatabaseMetaData.cxx |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit f26949e23d13d1b94d4b2bdfe8c4432d720d0fc8
Author:     Julien Nabet <serval2412 at yahoo.fr>
AuthorDate: Sun Dec 6 11:02:31 2020 +0100
Commit:     Julien Nabet <serval2412 at yahoo.fr>
CommitDate: Sun Dec 6 12:50:02 2020 +0100

    tdf#125957: FIREBIRD Datatype Binary(fix)[CHAR] couldn't be filled with content
    
    Really use sCharsetName which is xRow->getString(13) trimmed
    
    See commit bf662904c4b60e93c6b86e06288d41996eed12a2
    Author: Tamas Bunth <tamas.bunth at collabora.co.uk>
    Date:   Sat Dec 16 12:57:43 2017 +0100
    
        tdf#104734 Firebird: Add Binary (fix) type
    
        There is no explicit binary type in Firebird. It can be accomplished
        using the CHAR type with a special character set, which tells the
        database that it is binary data and there is no collation. (called
        OCTETS).
    
        Because of that, we also need the character set to decide the exact
        column type.
    
        And also refactor some parts of the driver:
        - Create class to determine internal type from firebird type, subtype,
        scale and character set.
        - Use internal type (DataType::XXX) in XDatabaseMetaData::getTypeInfo()
        indirectly. (We want to return a Firebird type for each internal type,
        not in the opposite direction.
    
    Change-Id: I3c9c764d353eeead5e8c00f1142846725eecce15
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107280
    Reviewed-by: Julien Nabet <serval2412 at yahoo.fr>
    Reviewed-by: Lionel Mamane <lionel at mamane.lu>
    Tested-by: Jenkins

diff --git a/connectivity/source/drivers/firebird/DatabaseMetaData.cxx b/connectivity/source/drivers/firebird/DatabaseMetaData.cxx
index 9aabd39cb52a..d06e7cc71985 100644
--- a/connectivity/source/drivers/firebird/DatabaseMetaData.cxx
+++ b/connectivity/source/drivers/firebird/DatabaseMetaData.cxx
@@ -1194,7 +1194,7 @@ uno::Reference< XResultSet > SAL_CALL ODatabaseMetaData::getColumns(
         // result field may be filled with spaces
         sCharsetName = sCharsetName.trim();
         ColumnTypeInfo aInfo(aType, xRow->getShort(7), aScale,
-                xRow->getString(13));
+                sCharsetName);
 
         aCurrentRow[5] = new ORowSetValueDecorator(aInfo.getSdbcType());
         // 6. Typename (SQL_*)


More information about the Libreoffice-commits mailing list