message: ExecuteBeforeFetch case needed.
diff: #include "duckdb_odbc.hpp"
  #include "statement_functions.hpp"
  #include "odbc_fetch.hpp"
  +#include "parameter_wrapper.hpp"
  SQLRETURN SQLGetData(SQLHSTMT statement_handle, SQLUSMALLINT col_or_param_num, SQLSMALLINT target_type,
  SQLPOINTER target_value_ptr, SQLLEN buffer_length, SQLLEN *str_len_or_ind_ptr) {
  @@ -9,7 +10,29 @@ SQLRETURN SQLGetData(SQLHSTMT statement_handle, SQLUSMALLINT col_or_param_num, S
  str_len_or_ind_ptr);
  }
  +static SQLRETURN ExecuteBeforeFetch(SQLHSTMT statement_handle) {
  + return duckdb::WithStatementPrepared(statement_handle, [&](duckdb::OdbcHandleStmt *stmt) -> SQLRETURN {
  + // case there is a result set, just fetch from it
  + if (stmt->res && stmt->res->success) {
  + return SQL_SUCCESS;
  + }
  + // check if it's needed to execute the stmt before fetch
  + if (stmt->param_wrapper->HasParamSetToProcess()) {
  + auto rc = duckdb::SingleExecuteStmt(stmt);
  + if (rc == SQL_SUCCESS || rc == SQL_STILL_EXECUTING) {
  + return SQL_SUCCESS;
  + }
  + return rc;
  + }
  + return SQL_SUCCESS;
  + });
  +}
  +
  SQLRETURN SQLFetch(SQLHSTMT statement_handle) {
  + auto ret = ExecuteBeforeFetch(statement_handle);
  + if (ret != SQL_SUCCESS) {
  + return ret;
  + }
  return duckdb::FetchStmtResult(statement_handle);
  }
  