Skip to content

Apache DataFusion SQL Query Engine

Make HashJoinExec::join_schema public (#12807)

Val Lorentzffe73fe03ae3
diff --git a/datafusion/physical-plan/src/joins/hash_join.rs b/datafusion/physical-plan/src/joins/hash_join.rs
index 48d648c89a..74a45a7e47 100644
--- a/datafusion/physical-plan/src/joins/hash_join.rs
+++ b/datafusion/physical-plan/src/joins/hash_join.rs
@@ -415,6 +415,12 @@ impl HashJoinExec {
&self.join_type
}
+ /// The schema after join. Please be careful when using this schema,
+ /// if there is a projection, the schema isn't the same as the output schema.
+ pub fn join_schema(&self) -> &SchemaRef {
+ &self.join_schema
+ }
+
/// The partitioning mode of this hash join
pub fn partition_mode(&self) -> &PartitionMode {
&self.mode