diff -r 85e6dc1853ee -r 428c278af4be src/DriverManager.cpp --- a/src/DriverManager.cpp Thu Jun 04 00:03:37 2020 +0200 +++ b/src/DriverManager.cpp Thu Jun 04 00:46:00 2020 +0200 @@ -69,11 +69,11 @@ (SQLCHAR*) dataSourceNameBytes.c_str(), SQL_NTS, (SQLCHAR*) userNameBytes.c_str(), SQL_NTS, (SQLCHAR*) passwordBytes.c_str(), SQL_NTS); - if (OdbcCommon::isNotSuccessful(result)) throw SqlException(L"Unable to connect to DSN: " + dataSourceName, result, SQL_HANDLE_DBC, connection, true); + if (OdbcCommon::isNotSuccessful(result)) throw SqlException(L"Unable to connect through DSN: " + dataSourceName, result, SQL_HANDLE_DBC, connection, true); return new Connection(connection); } -Connection* DriverManager::getConnectionByURL(relpipe::reader::string_t connectionString) { +Connection* DriverManager::getConnectionByString(relpipe::reader::string_t connectionString) { SQLHDBC connection = OdbcCommon::allocateHandle(SQL_HANDLE_DBC, environment); char completeConnectionString[SQL_MAX_OPTION_STRING_LENGTH]; memset(completeConnectionString, 0, sizeof (completeConnectionString)); @@ -82,7 +82,7 @@ (SQLCHAR*) convertor.to_bytes(connectionString).c_str(), SQL_NTS, (SQLCHAR*) completeConnectionString, sizeof (completeConnectionString), &completeConnectionStringLength, SQL_DRIVER_NOPROMPT); - if (OdbcCommon::isNotSuccessful(result)) throw SqlException(L"Unable to connect to URL: " + connectionString, result, SQL_HANDLE_DBC, connection, true); + if (OdbcCommon::isNotSuccessful(result)) throw SqlException(L"Unable to connect through string: " + connectionString, result, SQL_HANDLE_DBC, connection, true); return new Connection(connection); }