From 40ad9a3711e703fde3d78a5633e42113cb450705 Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Mon, 14 Feb 2022 14:46:52 +0000 Subject: enum class BulkUpdates --- libodbcpp/odbc-connection.cpp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/libodbcpp/odbc-connection.cpp b/libodbcpp/odbc-connection.cpp index a46a5f9..0cd5d19 100644 --- a/libodbcpp/odbc-connection.cpp +++ b/libodbcpp/odbc-connection.cpp @@ -14,7 +14,8 @@ NAMEDFACTORY("odbc", ODBC::Connection, DB::ConnectionFactory) ODBC::Connection::Connection(const DSN & d) : - env(nullptr), conn(nullptr), thinkDelStyle(DB::BulkDeleteUsingUsing), thinkUpdStyle(DB::BulkUpdateUsingFromSrc) + env(nullptr), conn(nullptr), thinkDelStyle(DB::BulkDeleteStyle::UsingUsing), + thinkUpdStyle(DB::BulkUpdateStyle::UsingFromSrc) { connectPre(); RETCODE dberr = SQLConnect(conn, const_cast(reinterpret_cast(d.dsn.c_str())), SQL_NTS, @@ -65,13 +66,14 @@ ODBC::Connection::connectPost() // Apply known DB specific tweaks // NOLINTNEXTLINE(hicpp-no-array-decay) if (strcasestr(reinterpret_cast(info.data()), "myodbc")) { - thinkDelStyle = DB::BulkDeleteUsingUsingAlias; - thinkUpdStyle = DB::BulkUpdateUsingJoin; + thinkDelStyle = DB::BulkDeleteStyle::UsingUsingAlias; + thinkUpdStyle = DB::BulkUpdateStyle::UsingJoin; } } ODBC::Connection::Connection(const std::string & s) : - env(nullptr), conn(nullptr), thinkDelStyle(DB::BulkDeleteUsingUsing), thinkUpdStyle(DB::BulkUpdateUsingFromSrc) + env(nullptr), conn(nullptr), thinkDelStyle(DB::BulkDeleteStyle::UsingUsing), + thinkUpdStyle(DB::BulkUpdateStyle::UsingFromSrc) { connectPre(); RETCODE dberr = SQLDriverConnect(conn, nullptr, const_cast(reinterpret_cast(s.c_str())), -- cgit v1.2.3