Skip to content

Commit

Permalink
Fixup after merge, now DuckDB v1.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
carlopi committed Feb 7, 2025
1 parent 80d0b4e commit 6114b61
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
8 changes: 4 additions & 4 deletions patches/duckdb/bind_copy_direct_io.patch
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
diff --git a/src/planner/binder/statement/bind_copy.cpp b/src/planner/binder/statement/bind_copy.cpp
index 7db1db812d..60131d5916 100644
index ce2f93ad86..140af5ba36 100644
--- a/src/planner/binder/statement/bind_copy.cpp
+++ b/src/planner/binder/statement/bind_copy.cpp
@@ -137,7 +137,9 @@ BoundStatement Binder::BindCopyTo(CopyStatement &stmt) {
throw NotImplementedException("Can't combine FILE_SIZE_BYTES and PARTITION_BY for COPY");
@@ -152,7 +152,9 @@ BoundStatement Binder::BindCopyTo(CopyStatement &stmt, CopyToType copy_to_type)
}
}
bool is_remote_file = FileSystem::IsRemoteFile(stmt.info->file_path);
- if (is_remote_file) {
+ if ( is_remote_file ) {
+ use_tmp_file = false;
+ } else if( config.options.use_direct_io ) {
+ } else if( context.db->config.options.use_direct_io ) {
use_tmp_file = false;
} else {
auto &fs = FileSystem::GetFileSystem(context);
10 changes: 5 additions & 5 deletions patches/duckdb/fix_load_database.patch
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
diff --git a/src/storage/storage_manager.cpp b/src/storage/storage_manager.cpp
index 456cd22614..c4777dd28e 100644
index cb6c654e5f..a6b2af3b85 100644
--- a/src/storage/storage_manager.cpp
+++ b/src/storage/storage_manager.cpp
@@ -163,9 +163,12 @@ void SingleFileStorageManager::LoadDatabase(const optional_idx block_alloc_size)
options.use_direct_io = config.options.use_direct_io;
options.debug_initialize = config.options.debug_initialize;

@@ -160,9 +160,12 @@ void SingleFileStorageManager::LoadDatabase(StorageOptions storage_options) {
row_group_size, STANDARD_VECTOR_SIZE);
}
}
- // Check if the database file already exists.
- // Note: a file can also exist if there was a ROLLBACK on a previous transaction creating that file.
- if (!read_only && !fs.FileExists(path)) {
Expand Down

0 comments on commit 6114b61

Please sign in to comment.