Skip to content

Commit e3796f7

Browse files
NGA-TRANappletreeisyellow
authored andcommitted
chore: add function to set prefer_existing_union (apache#10322)
1 parent be4d3f4 commit e3796f7

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

datafusion/execution/src/config.rs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -331,6 +331,14 @@ impl SessionConfig {
331331
self
332332
}
333333

334+
/// Prefer existing union (true). See [prefer_existing_union] for more details
335+
///
336+
/// [prefer_existing_union]: datafusion_common::config::OptimizerOptions::prefer_existing_union
337+
pub fn with_prefer_existing_union(mut self, enabled: bool) -> Self {
338+
self.options.optimizer.prefer_existing_union = enabled;
339+
self
340+
}
341+
334342
/// Enables or disables the use of pruning predicate for parquet readers to skip row groups
335343
pub fn with_parquet_pruning(mut self, enabled: bool) -> Self {
336344
self.options.execution.parquet.pruning = enabled;

0 commit comments

Comments
 (0)