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

Function SQLSetStmtAttr

cpp/src/arrow/flight/sql/odbc/odbc_api.cc:1018–1035  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1016}
1017
1018SQLRETURN SQLSetStmtAttr(SQLHSTMT stmt, SQLINTEGER attribute, SQLPOINTER value_ptr,
1019 SQLINTEGER string_length) {
1020 ARROW_LOG(DEBUG) << "SQLSetStmtAttrW called with stmt: " << stmt
1021 << ", attribute: " << attribute << ", value_ptr: " << value_ptr
1022 << ", string_length: " << string_length;
1023
1024 using ODBC::ODBCStatement;
1025
1026 return ODBCStatement::ExecuteWithDiagnostics(stmt, SQL_ERROR, [=]() {
1027 ODBCStatement* statement = reinterpret_cast<ODBCStatement*>(stmt);
1028
1029 bool is_unicode = true;
1030
1031 statement->SetStmtAttr(attribute, value_ptr, string_length, is_unicode);
1032
1033 return SQL_SUCCESS;
1034 });
1035}
1036
1037SQLRETURN SQLExecDirect(SQLHSTMT stmt, SQLWCHAR* query_text, SQLINTEGER text_length) {
1038 ARROW_LOG(DEBUG) << "SQLExecDirectW called with stmt: " << stmt

Callers 4

TYPED_TESTFunction · 0.50
ValidateSetStmtAttrFunction · 0.50
TYPED_TESTFunction · 0.50

Calls 1

SetStmtAttrMethod · 0.80

Tested by 4

TYPED_TESTFunction · 0.40
ValidateSetStmtAttrFunction · 0.40
TYPED_TESTFunction · 0.40