MCPcopy Create free account
hub / github.com/apache/arrow / ConnectWithString

Method ConnectWithString

cpp/src/arrow/flight/sql/odbc/tests/odbc_test_suite.cc:75–88  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

73}
74
75void ODBCTestBase::ConnectWithString(std::string connect_str) {
76 // Connect string
77 std::vector<SQLWCHAR> connect_str0(connect_str.begin(), connect_str.end());
78
79 SQLWCHAR out_str[kOdbcBufferSize];
80 SQLSMALLINT out_str_len;
81
82 // Connecting to ODBC server.
83 ASSERT_EQ(SQL_SUCCESS,
84 SQLDriverConnect(conn, NULL, &connect_str0[0],
85 static_cast<SQLSMALLINT>(connect_str0.size()), out_str,
86 kOdbcBufferSize, &out_str_len, SQL_DRIVER_NOPROMPT))
87 << GetOdbcErrorMessage(SQL_HANDLE_DBC, conn);
88}
89
90void ODBCTestBase::Disconnect() {
91 // Disconnect from ODBC

Callers 2

TYPED_TESTFunction · 0.80
TYPED_TESTFunction · 0.80

Calls 5

GetOdbcErrorMessageFunction · 0.85
SQLDriverConnectFunction · 0.50
beginMethod · 0.45
endMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected