tdf#121092: save db:suppress-version-columns to ODB

The setting is only available from ODatabaseSource itself, not from
its Settings property. So treat it separately on export (it is also
treated separately at import: see OXMLDataSource::OXMLDataSource).

Change-Id: I2ecdea8748e95380c123afdb9507dfa5a4abd838
Reviewed-on: https://gerrit.libreoffice.org/69031
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
diff --git a/dbaccess/source/filter/xml/xmlExport.cxx b/dbaccess/source/filter/xml/xmlExport.cxx
index e0cd1a1..f31f500 100644
--- a/dbaccess/source/filter/xml/xmlExport.cxx
+++ b/dbaccess/source/filter/xml/xmlExport.cxx
@@ -295,6 +295,17 @@
        static OUString s_sFalse(::xmloff::token::GetXMLToken( XML_FALSE ));
        // loop through the properties, and export only those which are not defaulted
        TSettingsMap aSettingsMap;
        // Don't try to get XPropertySetInfo from xProp, simply wrap the attempt into try block
        try
        {
            const Any aValue = xProp->getPropertyValue(PROPERTY_SUPPRESSVERSIONCL);
            if (!getBOOL(aValue)) // default in the XML schema is true -> only write false
                aSettingsMap.emplace(XML_SUPPRESS_VERSION_COLUMNS, s_sFalse);
        }
        catch (const UnknownPropertyException&)
        {
        }

        Sequence< Property > aProperties = xSettingsInfo->getProperties();
        const Property* pProperties = aProperties.getConstArray();
        const Property* pPropertiesEnd = pProperties + aProperties.getLength();
@@ -358,7 +369,6 @@
                PropertyMap( INFO_PARAMETERNAMESUBST,   XML_PARAMETER_NAME_SUBSTITUTION,    s_sTrue     ),
                PropertyMap( INFO_IGNOREDRIVER_PRIV,    XML_IGNORE_DRIVER_PRIVILEGES,       s_sTrue     ),
                PropertyMap( INFO_USECATALOG,           XML_USE_CATALOG,                    s_sFalse    ),
                PropertyMap( PROPERTY_SUPPRESSVERSIONCL,XML_SUPPRESS_VERSION_COLUMNS,       s_sTrue     ),
                PropertyMap( INFO_CONN_LDAP_BASEDN,     XML_BASE_DN                                     ),
                PropertyMap( INFO_CONN_LDAP_ROWCOUNT,   XML_MAX_ROW_COUNT                               )
            };