Skip to content

Commit a3317d9

Browse files
committed
Address comment
1 parent 289ccad commit a3317d9

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

Sources/SparkConnect/DataFrame.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -573,6 +573,7 @@ public actor DataFrame: Sendable {
573573
self.plan.root,
574574
right,
575575
SetOpType.union,
576+
isAll: true,
576577
byName: true,
577578
allowMissingColumns: allowMissingColumns
578579
)

Tests/SparkConnectTests/DataFrameTests.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -445,6 +445,8 @@ struct DataFrameTests {
445445
let df2 = try await spark.sql("SELECT 4 b, 3 a")
446446
#expect(try await df1.unionByName(df2).collect() == [Row("1", "2"), Row("3", "4")])
447447
#expect(try await df1.union(df2).collect() == [Row("1", "2"), Row("4", "3")])
448+
let df3 = try await spark.sql("SELECT * FROM VALUES 1, 1")
449+
#expect(try await df3.unionByName(df3).count() == 4)
448450
await spark.stop()
449451
}
450452
#endif

0 commit comments

Comments
 (0)