Skip to content

Commit

Permalink
Merge pull request duckdb#11732 from Tishj/alternative_verify_always_…
Browse files Browse the repository at this point in the history
…copy

[Dev] Always use `SQLStatement->Copy()` when ALTERNATIVE_VERIFY is defined
  • Loading branch information
Mytherin authored Apr 20, 2024
2 parents bfb8f48 + d6399e7 commit 14ae66d
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/main/client_context.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -763,6 +763,11 @@ void ClientContext::SetActiveResult(ClientContextLock &lock, BaseQueryResult &re
unique_ptr<PendingQueryResult> ClientContext::PendingStatementOrPreparedStatementInternal(
ClientContextLock &lock, const string &query, unique_ptr<SQLStatement> statement,
shared_ptr<PreparedStatementData> &prepared, const PendingQueryParameters &parameters) {
#ifdef DUCKDB_ALTERNATIVE_VERIFY
if (statement && statement->type != StatementType::LOGICAL_PLAN_STATEMENT) {
statement = statement->Copy();
}
#endif
// check if we are on AutoCommit. In this case we should start a transaction.
if (statement && config.AnyVerification()) {
// query verification is enabled
Expand Down

0 comments on commit 14ae66d

Please sign in to comment.