diff options
Diffstat (limited to 'connectivity/source/commontools/dbtools.cxx')
-rw-r--r-- | connectivity/source/commontools/dbtools.cxx | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/connectivity/source/commontools/dbtools.cxx b/connectivity/source/commontools/dbtools.cxx index b385eb7ac7f4..f5d564c21906 100644 --- a/connectivity/source/commontools/dbtools.cxx +++ b/connectivity/source/commontools/dbtools.cxx @@ -68,6 +68,7 @@ #include <comphelper/interaction.hxx> #include <comphelper/processfactory.hxx> #include <comphelper/property.hxx> +#include <comphelper/propertysequence.hxx> #include <connectivity/conncleanup.hxx> #include <connectivity/dbconversion.hxx> #include <connectivity/dbexception.hxx> @@ -410,11 +411,10 @@ SharedConnection lcl_connectRowSet(const Reference< XRowSet>& _rxRowSet, const R xRowSetProps->getPropertyValue(OMetaConnection::getPropMap().getNameByIndex(PROPERTY_ID_PASSWORD)) >>= sPwd; if (!sUser.isEmpty()) { // use user and pwd together with the url - Sequence< PropertyValue> aInfo(2); - aInfo.getArray()[0].Name = "user"; - aInfo.getArray()[0].Value <<= sUser; - aInfo.getArray()[1].Name = "password"; - aInfo.getArray()[1].Value <<= sPwd; + auto aInfo(::comphelper::InitPropertySequence({ + { "user", makeAny(sUser) }, + { "password", makeAny(sPwd) } + })); xPureConnection = xDriverManager->getConnectionWithInfo( sURL, aInfo ); } else |