[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.2' - connectivity/source
connectivity/source/drivers/mysqlc/mysqlc_connection.cxx |7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) New commits: commit 3598b74da8240190076f975fd7d1ff2b2d7d65dc Author: Tamas Bunth AuthorDate: Thu Sep 5 14:31:35 2019 +0200 Commit: Andras Timar CommitDate: Tue Sep 17 12:52:30 2019 +0200 mysqlc: Support connection to utf8mb4 server This charset is backward compatible with 'normal' utf-8. Change-Id: I4407894bf9029b9c56eb0d2530796e85bd226591 Reviewed-on: https://gerrit.libreoffice.org/78655 Tested-by: Jenkins CollaboraOffice Reviewed-by: Andras Timar diff --git a/connectivity/source/drivers/mysqlc/mysqlc_connection.cxx b/connectivity/source/drivers/mysqlc/mysqlc_connection.cxx index 981fe7392aa5..0c40866dc3e6 100644 --- a/connectivity/source/drivers/mysqlc/mysqlc_connection.cxx +++ b/connectivity/source/drivers/mysqlc/mysqlc_connection.cxx @@ -88,6 +88,8 @@ void OConnection::construct(const OUString& url, const Sequence& // use TCP as connection mysql_protocol_type protocol = MYSQL_PROTOCOL_TCP; mysql_options(&m_mysql, MYSQL_OPT_PROTOCOL, &protocol); +OString charset_name{ "utf8mb4" }; +mysql_options(&m_mysql, MYSQL_SET_CHARSET_NAME, charset_name.getStr()); sal_Int32 nIndex; OUString token; @@ -198,8 +200,9 @@ void OConnection::construct(const OUString& url, const Sequence& *this, OUString(), 0, Any()); } -lcl_executeUpdate(&m_mysql, OString{ "SET session sql_mode='ANSI_QUOTES'" }); -lcl_executeUpdate(&m_mysql, OString{ "SET NAMES utf8" }); +lcl_executeUpdate(&m_mysql, + OString{ "SET session sql_mode='ANSI_QUOTES,NO_AUTO_VALUE_ON_ZERO'" }); +lcl_executeUpdate(&m_mysql, OString{ "SET NAMES utf8mb4" }); } OUString OConnection::getImplementationName() ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.2' - connectivity/source
connectivity/source/drivers/mysqlc/mysqlc_databasemetadata.cxx |4 1 file changed, 4 deletions(-) New commits: commit 2e6c2abc59f0190c20f5096c803edfa763624e30 Author: Mike Kaganski AuthorDate: Mon Sep 16 13:46:17 2019 +0200 Commit: Mike Kaganski CommitDate: Mon Sep 16 13:49:03 2019 +0200 Fix Windows build after 19f8ea668833a4dc90244792cbf91881b0ca9a07 c:\lo\src\core\connectivity\source\drivers\mysqlc\mysqlc_databasemetadata.cxx(1058) : error C2220: warning treated as error - no 'object' file generated c:\lo\src\core\connectivity\source\drivers\mysqlc\mysqlc_databasemetadata.cxx(1058) : warning C4702: unreachable code Make code match commit acafd1ac87cb23a447353b8f0419a25fbe1c4430 in master Change-Id: I1da66e8cf97eb5820023c5bfa6342eb31cf89b74 Reviewed-on: https://gerrit.libreoffice.org/78984 Reviewed-by: Mike Kaganski Tested-by: Mike Kaganski diff --git a/connectivity/source/drivers/mysqlc/mysqlc_databasemetadata.cxx b/connectivity/source/drivers/mysqlc/mysqlc_databasemetadata.cxx index 736fa20d1f40..28319d00bd88 100644 --- a/connectivity/source/drivers/mysqlc/mysqlc_databasemetadata.cxx +++ b/connectivity/source/drivers/mysqlc/mysqlc_databasemetadata.cxx @@ -1049,13 +1049,9 @@ Reference SAL_CALL ODatabaseMetaData::getBestRowIdentifier(const Any Reference SAL_CALL ODatabaseMetaData::getTablePrivileges( const Any& /*catalog*/, const OUString& /*schemaPattern*/, const OUString& /*tableNamePattern*/) { -Reference xResultSet(getOwnConnection().getDriver().getFactory()->createInstance( - "org.openoffice.comp.helper.DatabaseMetaDataResultSet"), - UNO_QUERY); // TODO SAL_WARN("connectivity.mysqlc", "method not implemented"); throw SQLException("getTablePrivileges method not implemented", *this, "IM001", 0, Any()); -return xResultSet; } Reference SAL_CALL ODatabaseMetaData::getCrossReference( ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.2' - connectivity/source
connectivity/source/drivers/firebird/ResultSetMetaData.cxx |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) New commits: commit a624aa0e4c8ac86b40a84a072c2671f2f14c9a26 Author: Xisco Fauli AuthorDate: Wed Jul 10 16:00:56 2019 +0200 Commit: Andras Timar CommitDate: Sun Aug 4 21:01:29 2019 +0200 tdf#121528: Firebird stores scale as a negative number Change-Id: Ic301952aeef93d3035b04442e70705d08f45f95d Reviewed-on: https://gerrit.libreoffice.org/75357 Reviewed-by: Lionel Elie Mamane Tested-by: Jenkins (cherry picked from commit 3278dfd0a2c09f8a8862277dffd9ef666d4862c6) Reviewed-on: https://gerrit.libreoffice.org/75376 Reviewed-by: Xisco Faulí (cherry picked from commit 147d65c471efd4c0d4299dbaeac70922fac0f4f3) Reviewed-on: https://gerrit.libreoffice.org/75489 Reviewed-by: Tamás Bunth (cherry picked from commit d8ba2f6c559218191482489fa4d8e5b760ebbd5f) Reviewed-on: https://gerrit.libreoffice.org/76921 Tested-by: Jenkins CollaboraOffice Reviewed-by: Andras Timar diff --git a/connectivity/source/drivers/firebird/ResultSetMetaData.cxx b/connectivity/source/drivers/firebird/ResultSetMetaData.cxx index 6c1b8e8d09bb..f332b6e8bc18 100644 --- a/connectivity/source/drivers/firebird/ResultSetMetaData.cxx +++ b/connectivity/source/drivers/firebird/ResultSetMetaData.cxx @@ -106,7 +106,7 @@ sal_Int32 SAL_CALL OResultSetMetaData::getColumnType(sal_Int32 column) ColumnTypeInfo aInfo( m_pSqlda->sqlvar[column-1].sqltype, m_pSqlda->sqlvar[column-1].sqlsubtype, -m_pSqlda->sqlvar[column-1].sqlscale, +-(m_pSqlda->sqlvar[column-1].sqlscale), sCharset ); return aInfo.getSdbcType(); @@ -156,7 +156,7 @@ OUString SAL_CALL OResultSetMetaData::getColumnTypeName(sal_Int32 column) ColumnTypeInfo aInfo( m_pSqlda->sqlvar[column-1].sqltype, m_pSqlda->sqlvar[column-1].sqlsubtype, -m_pSqlda->sqlvar[column-1].sqlscale ); +-(m_pSqlda->sqlvar[column-1].sqlscale) ); return aInfo.getColumnTypeName(); } ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.2' - connectivity/source
connectivity/source/drivers/mysqlc/mysqlc_resultset.cxx |1 + 1 file changed, 1 insertion(+) New commits: commit 6cd885243952bec4b71aa95d77820b08d70a94dc Author: Tamas Bunth AuthorDate: Sat Dec 29 15:19:57 2018 +0100 Commit: Tamás Bunth CommitDate: Thu Aug 1 14:35:30 2019 +0200 mysqlc: ensure fetched result while invoking last Change-Id: Ia1872973eefff1d8d677aa443b0c03d3ea569d60 Reviewed-on: https://gerrit.libreoffice.org/65854 Reviewed-by: Andras Timar Tested-by: Andras Timar Reviewed-on: https://gerrit.libreoffice.org/76725 Tested-by: Jenkins CollaboraOffice Reviewed-by: Tamás Bunth diff --git a/connectivity/source/drivers/mysqlc/mysqlc_resultset.cxx b/connectivity/source/drivers/mysqlc/mysqlc_resultset.cxx index d6c2a9b724b4..be02c7c73ee3 100644 --- a/connectivity/source/drivers/mysqlc/mysqlc_resultset.cxx +++ b/connectivity/source/drivers/mysqlc/mysqlc_resultset.cxx @@ -612,6 +612,7 @@ sal_Bool SAL_CALL OResultSet::last() { MutexGuard aGuard(m_aMutex); checkDisposed(OResultSet_BASE::rBHelper.bDisposed); +ensureResultFetched(); m_nRowPosition = m_nRowCount - 1; return true; ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.2' - connectivity/source
connectivity/source/drivers/mysqlc/mysqlc_databasemetadata.cxx |3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) New commits: commit c2857c8acd90a7c832321ba0f30db2f6fc9279b3 Author: Tamas Bunth AuthorDate: Wed Sep 12 17:31:26 2018 +0200 Commit: Tamás Bunth CommitDate: Wed Jul 31 14:26:45 2019 +0200 mysqlc: getTablePrivileges not implemented, so.. it should throw an exception. Change-Id: I55fd8ed5d92a28096b9bde6b0161e16d7543203b Reviewed-on: https://gerrit.libreoffice.org/60460 Reviewed-by: Andras Timar Tested-by: Andras Timar Reviewed-on: https://gerrit.libreoffice.org/76721 Tested-by: Jenkins CollaboraOffice Reviewed-by: Tamás Bunth diff --git a/connectivity/source/drivers/mysqlc/mysqlc_databasemetadata.cxx b/connectivity/source/drivers/mysqlc/mysqlc_databasemetadata.cxx index 890f31de666a..f4355ae7a169 100644 --- a/connectivity/source/drivers/mysqlc/mysqlc_databasemetadata.cxx +++ b/connectivity/source/drivers/mysqlc/mysqlc_databasemetadata.cxx @@ -1050,10 +1050,9 @@ Reference SAL_CALL ODatabaseMetaData::getTablePrivileges( Reference xResultSet(getOwnConnection().getDriver().getFactory()->createInstance( "org.openoffice.comp.helper.DatabaseMetaDataResultSet"), UNO_QUERY); -std::vector> rRows; // TODO SAL_WARN("connectivity.mysqlc", "method not implemented"); -lcl_setRows_throw(xResultSet, 12, rRows); +throw SQLException("getTablePrivileges method not implemented", *this, "IM001", 0, Any()); return xResultSet; } ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits