This is an automated email from the ASF dual-hosted git repository.
jimjag pushed a commit to branch odf-devel
in repository https://gitbox.apache.org/repos/asf/openoffice.git
The following commit(s) were added to refs/heads/odf-devel by this push:
new 674f0a66dd dbaccess: write server databases as db:connection-resource
in ODF 1.2 strict mode
674f0a66dd is described below
commit 674f0a66ddf51066d2df8f925effcc0e79d2906e
Author: Jim Jagielski <[email protected]>
AuthorDate: Thu Oct 29 09:40:16 2026 -0400
dbaccess: write server databases as db:connection-resource in ODF 1.2
strict mode
---
main/dbaccess/source/filter/xml/xmlExport.cxx | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/main/dbaccess/source/filter/xml/xmlExport.cxx
b/main/dbaccess/source/filter/xml/xmlExport.cxx
index 5c56677af2..ecbf283564 100644
--- a/main/dbaccess/source/filter/xml/xmlExport.cxx
+++ b/main/dbaccess/source/filter/xml/xmlExport.cxx
@@ -613,7 +613,8 @@ void ODBExport::exportConnectionData()
String sDatabaseName,sHostName;
sal_Int32 nPort = -1;
m_aTypeCollection.extractHostNamePort(sValue,sDatabaseName,sHostName,nPort);
- if ( sHostName.Len() )
+ // db:type must use a declared namespace prefix in ODF 1.2, so the
URL goes into the connection resource
+ if ( sHostName.Len() && SvtSaveOptions().GetODFDefaultVersion() !=
SvtSaveOptions::ODFVER_012 )
{
SvXMLElementExport
aDatabaseDescription(*this,XML_NAMESPACE_DB, XML_DATABASE_DESCRIPTION,
sal_True, sal_True);
{