@@ -1863,7 +1863,7 @@ async fn with_column_renamed_join() -> Result<()> {
1863
1863
assert_snapshot ! (
1864
1864
df_renamed. logical_plan( ) ,
1865
1865
@r"
1866
- Projection: t1.c1 AS AAA, t1.c2, t1.c3, t2.c1, t2.c2, t2.c3
1866
+ Projection: t1.c1 AS t1. AAA, t1.c2, t1.c3, t2.c1, t2.c2, t2.c3
1867
1867
Limit: skip=0, fetch=1
1868
1868
Sort: t1.c1 ASC NULLS FIRST, t1.c2 ASC NULLS FIRST, t1.c3 ASC NULLS FIRST, t2.c1 ASC NULLS FIRST, t2.c2 ASC NULLS FIRST, t2.c3 ASC NULLS FIRST
1869
1869
Inner Join: t1.c1 = t2.c1
@@ -1878,15 +1878,15 @@ async fn with_column_renamed_join() -> Result<()> {
1878
1878
1879
1879
assert_snapshot ! (
1880
1880
df_renamed. clone( ) . into_optimized_plan( ) . unwrap( ) ,
1881
- @r### "
1882
- Projection: t1.c1 AS AAA, t1.c2, t1.c3, t2.c1, t2.c2, t2.c3
1881
+ @r"
1882
+ Projection: t1.c1 AS t1. AAA, t1.c2, t1.c3, t2.c1, t2.c2, t2.c3
1883
1883
Sort: t1.c1 ASC NULLS FIRST, t1.c2 ASC NULLS FIRST, t1.c3 ASC NULLS FIRST, t2.c1 ASC NULLS FIRST, t2.c2 ASC NULLS FIRST, t2.c3 ASC NULLS FIRST, fetch=1
1884
1884
Inner Join: t1.c1 = t2.c1
1885
1885
SubqueryAlias: t1
1886
1886
TableScan: aggregate_test_100 projection=[c1, c2, c3]
1887
1887
SubqueryAlias: t2
1888
1888
TableScan: aggregate_test_100 projection=[c1, c2, c3]
1889
- "###
1889
+ "
1890
1890
) ;
1891
1891
1892
1892
let df_results = df_renamed. collect ( ) . await ?;
@@ -3606,12 +3606,12 @@ async fn join_with_alias_filter() -> Result<()> {
3606
3606
let actual = formatted. trim ( ) ;
3607
3607
assert_snapshot ! (
3608
3608
actual,
3609
- @r### "
3610
- Projection: t1.a, t2.a, t1.b, t1.c, t2.b, t2.c [a:UInt32, a:UInt32, b:Utf8, c:Int32, b:Utf8, c:Int32]
3611
- Inner Join: t1.a + UInt32(3) = t2.a + UInt32(1) [a:UInt32, b:Utf8, c:Int32, a:UInt32, b:Utf8, c:Int32]
3612
- TableScan: t1 projection=[a, b, c] [a:UInt32, b:Utf8, c:Int32]
3613
- TableScan: t2 projection=[a, b, c] [a:UInt32, b:Utf8, c:Int32]
3614
- "###
3609
+ @r"
3610
+ Projection: t1.a, t2.a, t1.b, t1.c, t2.b, t2.c [t1. a:UInt32, t2. a:UInt32, t1. b:Utf8, t1. c:Int32, t2. b:Utf8, t2. c:Int32]
3611
+ Inner Join: t1.a + UInt32(3) = t2.a + UInt32(1) [t1. a:UInt32, t1. b:Utf8, t1. c:Int32, t2. a:UInt32, t2. b:Utf8, t2. c:Int32]
3612
+ TableScan: t1 projection=[a, b, c] [t1. a:UInt32, t1. b:Utf8, t1. c:Int32]
3613
+ TableScan: t2 projection=[a, b, c] [t2. a:UInt32, t2. b:Utf8, t2. c:Int32]
3614
+ "
3615
3615
) ;
3616
3616
3617
3617
let results = df. collect ( ) . await ?;
@@ -3651,14 +3651,14 @@ async fn right_semi_with_alias_filter() -> Result<()> {
3651
3651
let actual = formatted. trim ( ) ;
3652
3652
assert_snapshot ! (
3653
3653
actual,
3654
- @r### "
3655
- RightSemi Join: t1.a = t2.a [a:UInt32, b:Utf8, c:Int32]
3656
- Projection: t1.a [a:UInt32]
3657
- Filter: t1.c > Int32(1) [a:UInt32, c:Int32]
3658
- TableScan: t1 projection=[a, c] [a:UInt32, c:Int32]
3659
- Filter: t2.c > Int32(1) [a:UInt32, b:Utf8, c:Int32]
3660
- TableScan: t2 projection=[a, b, c] [a:UInt32, b:Utf8, c:Int32]
3661
- "###
3654
+ @r"
3655
+ RightSemi Join: t1.a = t2.a [t2. a:UInt32, t2. b:Utf8, t2. c:Int32]
3656
+ Projection: t1.a [t1. a:UInt32]
3657
+ Filter: t1.c > Int32(1) [t1. a:UInt32, t1. c:Int32]
3658
+ TableScan: t1 projection=[a, c] [t1. a:UInt32, t1. c:Int32]
3659
+ Filter: t2.c > Int32(1) [t2. a:UInt32, t2. b:Utf8, t2. c:Int32]
3660
+ TableScan: t2 projection=[a, b, c] [t2. a:UInt32, t2. b:Utf8, t2. c:Int32]
3661
+ "
3662
3662
) ;
3663
3663
3664
3664
let results = df. collect ( ) . await ?;
@@ -3698,13 +3698,13 @@ async fn right_anti_filter_push_down() -> Result<()> {
3698
3698
let actual = formatted. trim ( ) ;
3699
3699
assert_snapshot ! (
3700
3700
actual,
3701
- @r### "
3702
- RightAnti Join: t1.a = t2.a Filter: t2.c > Int32(1) [a:UInt32, b:Utf8, c:Int32]
3703
- Projection: t1.a [a:UInt32]
3704
- Filter: t1.c > Int32(1) [a:UInt32, c:Int32]
3705
- TableScan: t1 projection=[a, c] [a:UInt32, c:Int32]
3706
- TableScan: t2 projection=[a, b, c] [a:UInt32, b:Utf8, c:Int32]
3707
- "###
3701
+ @r"
3702
+ RightAnti Join: t1.a = t2.a Filter: t2.c > Int32(1) [t2. a:UInt32, t2. b:Utf8, t2. c:Int32]
3703
+ Projection: t1.a [t1. a:UInt32]
3704
+ Filter: t1.c > Int32(1) [t1. a:UInt32, t1. c:Int32]
3705
+ TableScan: t1 projection=[a, c] [t1. a:UInt32, t1. c:Int32]
3706
+ TableScan: t2 projection=[a, b, c] [t2. a:UInt32, t2. b:Utf8, t2. c:Int32]
3707
+ "
3708
3708
) ;
3709
3709
3710
3710
let results = df. collect ( ) . await ?;
@@ -4382,12 +4382,12 @@ async fn unnest_with_redundant_columns() -> Result<()> {
4382
4382
let actual = formatted. trim ( ) ;
4383
4383
assert_snapshot ! (
4384
4384
actual,
4385
- @r### "
4386
- Projection: shapes.shape_id [shape_id:UInt32]
4387
- Unnest: lists[shape_id2|depth=1] structs[] [shape_id:UInt32, shape_id2:UInt32;N]
4388
- Aggregate: groupBy=[[shapes.shape_id]], aggr=[[array_agg(shapes.shape_id) AS shape_id2]] [shape_id:UInt32, shape_id2:List(Field { name: "item", data_type: UInt32, nullable: true, dict_id: 0, dict_is_ordered: false, metadata: {} });N]
4389
- TableScan: shapes projection=[shape_id] [shape_id:UInt32]
4390
- "###
4385
+ @r#"
4386
+ Projection: shapes.shape_id [shapes. shape_id:UInt32]
4387
+ Unnest: lists[shape_id2|depth=1] structs[] [shapes. shape_id:UInt32, shape_id2:UInt32;N]
4388
+ Aggregate: groupBy=[[shapes.shape_id]], aggr=[[array_agg(shapes.shape_id) AS shape_id2]] [shapes. shape_id:UInt32, shape_id2:List(Field { name: "item", data_type: UInt32, nullable: true, dict_id: 0, dict_is_ordered: false, metadata: {} });N]
4389
+ TableScan: shapes projection=[shape_id] [shapes. shape_id:UInt32]
4390
+ "#
4391
4391
) ;
4392
4392
4393
4393
let results = df. collect ( ) . await ?;
@@ -5748,11 +5748,11 @@ async fn test_alias() -> Result<()> {
5748
5748
. into_unoptimized_plan ( )
5749
5749
. display_indent_schema ( )
5750
5750
. to_string ( ) ;
5751
- assert_snapshot ! ( plan, @r### "
5752
- SubqueryAlias: table_alias [a:Utf8, b:Int32, one:Int32]
5753
- Projection: test.a, test.b, Int32(1) AS one [a:Utf8, b:Int32, one:Int32]
5754
- TableScan: test [a:Utf8, b:Int32]
5755
- "### ) ;
5751
+ assert_snapshot ! ( plan, @r"
5752
+ SubqueryAlias: table_alias [table_alias. a:Utf8, table_alias. b:Int32, table_alias. one:Int32]
5753
+ Projection: test.a, test.b, Int32(1) AS one [test. a:Utf8, test. b:Int32, one:Int32]
5754
+ TableScan: test [test. a:Utf8, test. b:Int32]
5755
+ " ) ;
5756
5756
5757
5757
// Select over the aliased DataFrame
5758
5758
let df = df. select ( vec ! [
@@ -5822,10 +5822,10 @@ async fn test_alias_empty() -> Result<()> {
5822
5822
. into_unoptimized_plan ( )
5823
5823
. display_indent_schema ( )
5824
5824
. to_string ( ) ;
5825
- assert_snapshot ! ( plan, @r### "
5826
- SubqueryAlias: [a:Utf8, b:Int32]
5827
- TableScan: test [a:Utf8, b:Int32]
5828
- "### ) ;
5825
+ assert_snapshot ! ( plan, @r"
5826
+ SubqueryAlias: [. a:Utf8, . b:Int32]
5827
+ TableScan: test [test. a:Utf8, test. b:Int32]
5828
+ " ) ;
5829
5829
5830
5830
assert_snapshot ! (
5831
5831
batches_to_sort_string( & df. select( vec![ col( "a" ) , col( "b" ) ] ) ?. collect( ) . await . unwrap( ) ) ,
@@ -5857,12 +5857,12 @@ async fn test_alias_nested() -> Result<()> {
5857
5857
. into_optimized_plan ( ) ?
5858
5858
. display_indent_schema ( )
5859
5859
. to_string ( ) ;
5860
- assert_snapshot ! ( plan, @r### "
5861
- SubqueryAlias: alias2 [a:Utf8, b:Int32, one:Int32]
5862
- SubqueryAlias: alias1 [a:Utf8, b:Int32, one:Int32]
5863
- Projection: test.a, test.b, Int32(1) AS one [a:Utf8, b:Int32, one:Int32]
5864
- TableScan: test projection=[a, b] [a:Utf8, b:Int32]
5865
- "### ) ;
5860
+ assert_snapshot ! ( plan, @r"
5861
+ SubqueryAlias: alias2 [alias2. a:Utf8, alias2. b:Int32, alias2. one:Int32]
5862
+ SubqueryAlias: alias1 [alias1. a:Utf8, alias1. b:Int32, alias1. one:Int32]
5863
+ Projection: test.a, test.b, Int32(1) AS one [test. a:Utf8, test. b:Int32, one:Int32]
5864
+ TableScan: test projection=[a, b] [test. a:Utf8, test. b:Int32]
5865
+ " ) ;
5866
5866
5867
5867
// Select over the aliased DataFrame
5868
5868
let select1 = df
0 commit comments