Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion datafusion-testing
14 changes: 10 additions & 4 deletions datafusion/expr/src/expr.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1850,7 +1850,7 @@ impl Expr {

/// Return `self AS name` alias expression
pub fn alias(self, name: impl Into<String>) -> Expr {
Expr::Alias(Alias::new(self, None::<&str>, name.into()))
Expr::Alias(Alias::new(self.unalias(), None::<TableReference>, name))
}

/// Return `self AS name` alias expression with metadata
Expand Down Expand Up @@ -1881,7 +1881,7 @@ impl Expr {
relation: Option<impl Into<TableReference>>,
name: impl Into<String>,
) -> Expr {
Expr::Alias(Alias::new(self, relation, name.into()))
Expr::Alias(Alias::new(self.unalias(), relation, name))
}

/// Return `self AS name` alias expression with a specific qualifier and metadata
Expand Down Expand Up @@ -1915,7 +1915,8 @@ impl Expr {
///
/// # Example
/// ```
/// # use datafusion_expr::col;
/// # use datafusion_expr::{col, Expr};
/// # use datafusion_expr::expr::Alias;
/// // `foo as "bar"` is unaliased to `foo`
/// let expr = col("foo").alias("bar");
/// assert_eq!(expr.unalias(), col("foo"));
Expand All @@ -1925,7 +1926,12 @@ impl Expr {
/// assert_eq!(expr.clone().unalias(), expr);
///
/// // `foo as "bar" as "baz" is unaliased to foo as "bar"
/// let expr = col("foo").alias("bar").alias("baz");
/// let expr = Expr::Alias(Alias {
/// expr: Box::new(col("foo").alias("bar")),
/// name: "baz".to_owned(),
/// relation: None,
/// metadata: None
/// });
/// assert_eq!(expr.unalias(), col("foo").alias("bar"));
/// ```
pub fn unalias(self) -> Expr {
Expand Down
2 changes: 1 addition & 1 deletion datafusion/optimizer/src/analyzer/type_coercion.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1275,7 +1275,7 @@ fn project_with_column_index(
.enumerate()
.map(|(i, e)| match e {
Expr::Alias(Alias { ref name, .. }) if name != schema.field(i).name() => {
Ok(e.unalias().alias(schema.field(i).name()))
Ok(e.alias(schema.field(i).name()))
}
Expr::Column(Column {
relation: _,
Expand Down
2 changes: 1 addition & 1 deletion datafusion/optimizer/tests/optimizer_integration.rs
Original file line number Diff line number Diff line change
Expand Up @@ -447,7 +447,7 @@ fn eliminate_redundant_null_check_on_count() {
assert_snapshot!(
format!("{plan}"),
@r"
Projection: test.col_int32, count(Int64(1)) AS count(*) AS c
Projection: test.col_int32, count(Int64(1)) AS c
Aggregate: groupBy=[[test.col_int32]], aggr=[[count(Int64(1))]]
TableScan: test projection=[col_int32]
"
Expand Down
15 changes: 10 additions & 5 deletions datafusion/sql/src/utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -703,12 +703,13 @@ mod tests {
use arrow::datatypes::{DataType as ArrowDataType, Field, Fields, Schema};
use datafusion_common::{Column, DFSchema, Result};
use datafusion_expr::{
ColumnUnnestList, EmptyRelation, LogicalPlan, col, lit, unnest,
ColumnUnnestList, EmptyRelation, Expr, LogicalPlan, col, lit, unnest,
};
use datafusion_functions::core::expr_ext::FieldAccessor;
use datafusion_functions_aggregate::expr_fn::count;

use crate::utils::{resolve_positions_to_exprs, rewrite_recursive_unnest_bottom_up};
use datafusion_expr::expr::Alias;
use indexmap::IndexMap;

fn column_unnests_eq(
Expand Down Expand Up @@ -813,10 +814,14 @@ mod tests {

assert_eq!(
transformed_exprs,
vec![
(col("__unnest_placeholder(3d_col,depth=1)").alias("UNNEST(3d_col)"))
.alias("2d_col")
]
vec![Expr::Alias(Alias {
expr: Box::new(
col("__unnest_placeholder(3d_col,depth=1)").alias("UNNEST(3d_col)")
),
relation: None,
name: "2d_col".to_owned(),
metadata: None,
})]
);
column_unnests_eq(
vec![
Expand Down
2 changes: 1 addition & 1 deletion datafusion/sqllogictest/test_files/aggregate.slt
Original file line number Diff line number Diff line change
Expand Up @@ -8832,7 +8832,7 @@ ORDER BY g;

# Config reset

# The SLT runner sets `target_partitions` to 4 instead of using the default, so
# The SLT runner sets `target_partitions` to 4 instead of using the default, so
# reset it explicitly.
statement ok
set datafusion.execution.target_partitions = 4;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ physical_plan

# Config reset

# The SLT runner sets `target_partitions` to 4 instead of using the default, so
# The SLT runner sets `target_partitions` to 4 instead of using the default, so
# reset it explicitly.
statement ok
SET datafusion.execution.target_partitions = 4;
6 changes: 3 additions & 3 deletions datafusion/sqllogictest/test_files/aggregate_skip_partial.slt
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ e true false NULL
statement ok
reset datafusion.execution.batch_size;

# The SLT runner sets `target_partitions` to 4 instead of using the default, so
# The SLT runner sets `target_partitions` to 4 instead of using the default, so
# reset it explicitly.
statement ok
set datafusion.execution.target_partitions = 4;
Expand Down Expand Up @@ -712,7 +712,7 @@ ORDER BY i;
statement ok
reset datafusion.execution.batch_size;

# The SLT runner sets `target_partitions` to 4 instead of using the default, so
# The SLT runner sets `target_partitions` to 4 instead of using the default, so
# reset it explicitly.
statement ok
set datafusion.execution.target_partitions = 4;
Expand Down Expand Up @@ -772,7 +772,7 @@ true false false false false true false NULL
statement ok
reset datafusion.execution.batch_size;

# The SLT runner sets `target_partitions` to 4 instead of using the default, so
# The SLT runner sets `target_partitions` to 4 instead of using the default, so
# reset it explicitly.
statement ok
set datafusion.execution.target_partitions = 4;
Expand Down
1 change: 0 additions & 1 deletion datafusion/sqllogictest/test_files/array/cleanup.slt.part
Original file line number Diff line number Diff line change
Expand Up @@ -167,4 +167,3 @@ drop table large_arrays_values_without_nulls;

statement ok
drop table fixed_size_arrays_values_without_nulls;

2 changes: 0 additions & 2 deletions datafusion/sqllogictest/test_files/array/init_data.slt.part
Original file line number Diff line number Diff line change
Expand Up @@ -688,5 +688,3 @@ AS
arrow_cast(column4, 'FixedSizeList(3, Float64)') AS column4
FROM arrays_distance_table
;


36 changes: 18 additions & 18 deletions datafusion/sqllogictest/test_files/clickbench.slt
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ EXPLAIN SELECT "RegionID", SUM("AdvEngineID"), COUNT(*) AS c, AVG("ResolutionWid
----
logical_plan
01)Sort: c DESC NULLS FIRST, fetch=10
02)--Projection: hits.RegionID, sum(hits.AdvEngineID), count(Int64(1)) AS count(*) AS c, avg(hits.ResolutionWidth), count(DISTINCT hits.UserID)
02)--Projection: hits.RegionID, sum(hits.AdvEngineID), count(Int64(1)) AS c, avg(hits.ResolutionWidth), count(DISTINCT hits.UserID)
03)----Aggregate: groupBy=[[hits.RegionID]], aggr=[[sum(CAST(hits.AdvEngineID AS Int64)), count(Int64(1)), avg(CAST(hits.ResolutionWidth AS Float64)), count(DISTINCT hits.UserID)]]
04)------SubqueryAlias: hits
05)--------TableScan: hits_raw projection=[RegionID, UserID, ResolutionWidth, AdvEngineID]
Expand Down Expand Up @@ -350,7 +350,7 @@ EXPLAIN SELECT "SearchPhrase", COUNT(*) AS c FROM hits WHERE "SearchPhrase" <> '
----
logical_plan
01)Sort: c DESC NULLS FIRST, fetch=10
02)--Projection: hits.SearchPhrase, count(Int64(1)) AS count(*) AS c
02)--Projection: hits.SearchPhrase, count(Int64(1)) AS c
03)----Aggregate: groupBy=[[hits.SearchPhrase]], aggr=[[count(Int64(1))]]
04)------SubqueryAlias: hits
05)--------Filter: hits_raw.SearchPhrase != Utf8View("")
Expand Down Expand Up @@ -406,7 +406,7 @@ EXPLAIN SELECT "SearchEngineID", "SearchPhrase", COUNT(*) AS c FROM hits WHERE "
----
logical_plan
01)Sort: c DESC NULLS FIRST, fetch=10
02)--Projection: hits.SearchEngineID, hits.SearchPhrase, count(Int64(1)) AS count(*) AS c
02)--Projection: hits.SearchEngineID, hits.SearchPhrase, count(Int64(1)) AS c
03)----Aggregate: groupBy=[[hits.SearchEngineID, hits.SearchPhrase]], aggr=[[count(Int64(1))]]
04)------SubqueryAlias: hits
05)--------Filter: hits_raw.SearchPhrase != Utf8View("")
Expand Down Expand Up @@ -590,7 +590,7 @@ EXPLAIN SELECT "SearchPhrase", MIN("URL"), COUNT(*) AS c FROM hits WHERE "URL" L
----
logical_plan
01)Sort: c DESC NULLS FIRST, fetch=10
02)--Projection: hits.SearchPhrase, min(hits.URL), count(Int64(1)) AS count(*) AS c
02)--Projection: hits.SearchPhrase, min(hits.URL), count(Int64(1)) AS c
03)----Aggregate: groupBy=[[hits.SearchPhrase]], aggr=[[min(hits.URL), count(Int64(1))]]
04)------SubqueryAlias: hits
05)--------Filter: hits_raw.URL LIKE Utf8View("%google%") AND hits_raw.SearchPhrase != Utf8View("")
Expand All @@ -616,7 +616,7 @@ EXPLAIN SELECT "SearchPhrase", MIN("URL"), MIN("Title"), COUNT(*) AS c, COUNT(DI
----
logical_plan
01)Sort: c DESC NULLS FIRST, fetch=10
02)--Projection: hits.SearchPhrase, min(hits.URL), min(hits.Title), count(Int64(1)) AS count(*) AS c, count(DISTINCT hits.UserID)
02)--Projection: hits.SearchPhrase, min(hits.URL), min(hits.Title), count(Int64(1)) AS c, count(DISTINCT hits.UserID)
03)----Aggregate: groupBy=[[hits.SearchPhrase]], aggr=[[min(hits.URL), min(hits.Title), count(Int64(1)), count(DISTINCT hits.UserID)]]
04)------SubqueryAlias: hits
05)--------Filter: hits_raw.Title LIKE Utf8View("%Google%") AND hits_raw.URL NOT LIKE Utf8View("%.google.%") AND hits_raw.SearchPhrase != Utf8View("")
Expand Down Expand Up @@ -730,7 +730,7 @@ EXPLAIN SELECT "CounterID", AVG(length("URL")) AS l, COUNT(*) AS c FROM hits WHE
----
logical_plan
01)Sort: l DESC NULLS FIRST, fetch=25
02)--Projection: hits.CounterID, avg(length(hits.URL)) AS l, count(Int64(1)) AS count(*) AS c
02)--Projection: hits.CounterID, avg(length(hits.URL)) AS l, count(Int64(1)) AS c
03)----Filter: count(Int64(1)) > Int64(100000)
04)------Aggregate: groupBy=[[hits.CounterID]], aggr=[[avg(CAST(character_length(hits.URL) AS length(hits.URL) AS Float64)), count(Int64(1))]]
05)--------SubqueryAlias: hits
Expand Down Expand Up @@ -758,7 +758,7 @@ EXPLAIN SELECT REGEXP_REPLACE("Referer", '^https?://(?:www\.)?([^/]+)/.*$', '\1'
----
logical_plan
01)Sort: l DESC NULLS FIRST, fetch=25
02)--Projection: regexp_replace(hits.Referer,Utf8("^https?://(?:www\.)?([^/]+)/.*$"),Utf8("\1")) AS k, avg(length(hits.Referer)) AS l, count(Int64(1)) AS count(*) AS c, min(hits.Referer)
02)--Projection: regexp_replace(hits.Referer,Utf8("^https?://(?:www\.)?([^/]+)/.*$"),Utf8("\1")) AS k, avg(length(hits.Referer)) AS l, count(Int64(1)) AS c, min(hits.Referer)
03)----Filter: count(Int64(1)) > Int64(100000)
04)------Aggregate: groupBy=[[regexp_replace(hits.Referer, Utf8View("^https?://(?:www\.)?([^/]+)/.*$"), Utf8View("\1")) AS regexp_replace(hits.Referer,Utf8("^https?://(?:www\.)?([^/]+)/.*$"),Utf8("\1"))]], aggr=[[avg(CAST(character_length(hits.Referer) AS length(hits.Referer) AS Float64)), count(Int64(1)), min(hits.Referer)]]
05)--------SubqueryAlias: hits
Expand Down Expand Up @@ -807,7 +807,7 @@ EXPLAIN SELECT "SearchEngineID", "ClientIP", COUNT(*) AS c, SUM("IsRefresh"), AV
----
logical_plan
01)Sort: c DESC NULLS FIRST, fetch=10
02)--Projection: hits.SearchEngineID, hits.ClientIP, count(Int64(1)) AS count(*) AS c, sum(hits.IsRefresh), avg(hits.ResolutionWidth)
02)--Projection: hits.SearchEngineID, hits.ClientIP, count(Int64(1)) AS c, sum(hits.IsRefresh), avg(hits.ResolutionWidth)
03)----Aggregate: groupBy=[[hits.SearchEngineID, hits.ClientIP]], aggr=[[count(Int64(1)), sum(CAST(hits.IsRefresh AS Int64)), avg(CAST(hits.ResolutionWidth AS Float64))]]
04)------SubqueryAlias: hits
05)--------Projection: hits_raw.ClientIP, hits_raw.IsRefresh, hits_raw.ResolutionWidth, hits_raw.SearchEngineID
Expand All @@ -834,7 +834,7 @@ EXPLAIN SELECT "WatchID", "ClientIP", COUNT(*) AS c, SUM("IsRefresh"), AVG("Reso
----
logical_plan
01)Sort: c DESC NULLS FIRST, fetch=10
02)--Projection: hits.WatchID, hits.ClientIP, count(Int64(1)) AS count(*) AS c, sum(hits.IsRefresh), avg(hits.ResolutionWidth)
02)--Projection: hits.WatchID, hits.ClientIP, count(Int64(1)) AS c, sum(hits.IsRefresh), avg(hits.ResolutionWidth)
03)----Aggregate: groupBy=[[hits.WatchID, hits.ClientIP]], aggr=[[count(Int64(1)), sum(CAST(hits.IsRefresh AS Int64)), avg(CAST(hits.ResolutionWidth AS Float64))]]
04)------SubqueryAlias: hits
05)--------Projection: hits_raw.WatchID, hits_raw.ClientIP, hits_raw.IsRefresh, hits_raw.ResolutionWidth
Expand All @@ -861,7 +861,7 @@ EXPLAIN SELECT "WatchID", "ClientIP", COUNT(*) AS c, SUM("IsRefresh"), AVG("Reso
----
logical_plan
01)Sort: c DESC NULLS FIRST, fetch=10
02)--Projection: hits.WatchID, hits.ClientIP, count(Int64(1)) AS count(*) AS c, sum(hits.IsRefresh), avg(hits.ResolutionWidth)
02)--Projection: hits.WatchID, hits.ClientIP, count(Int64(1)) AS c, sum(hits.IsRefresh), avg(hits.ResolutionWidth)
03)----Aggregate: groupBy=[[hits.WatchID, hits.ClientIP]], aggr=[[count(Int64(1)), sum(CAST(hits.IsRefresh AS Int64)), avg(CAST(hits.ResolutionWidth AS Float64))]]
04)------SubqueryAlias: hits
05)--------TableScan: hits_raw projection=[WatchID, ClientIP, IsRefresh, ResolutionWidth]
Expand Down Expand Up @@ -894,7 +894,7 @@ EXPLAIN SELECT "URL", COUNT(*) AS c FROM hits GROUP BY "URL" ORDER BY c DESC LIM
----
logical_plan
01)Sort: c DESC NULLS FIRST, fetch=10
02)--Projection: hits.URL, count(Int64(1)) AS count(*) AS c
02)--Projection: hits.URL, count(Int64(1)) AS c
03)----Aggregate: groupBy=[[hits.URL]], aggr=[[count(Int64(1))]]
04)------SubqueryAlias: hits
05)--------TableScan: hits_raw projection=[URL]
Expand Down Expand Up @@ -981,7 +981,7 @@ EXPLAIN SELECT "URL", COUNT(*) AS PageViews FROM hits WHERE "CounterID" = 62 AND
----
logical_plan
01)Sort: pageviews DESC NULLS FIRST, fetch=10
02)--Projection: hits.URL, count(Int64(1)) AS count(*) AS pageviews
02)--Projection: hits.URL, count(Int64(1)) AS pageviews
03)----Aggregate: groupBy=[[hits.URL]], aggr=[[count(Int64(1))]]
04)------SubqueryAlias: hits
05)--------Projection: hits_raw.URL
Expand All @@ -1008,7 +1008,7 @@ EXPLAIN SELECT "Title", COUNT(*) AS PageViews FROM hits WHERE "CounterID" = 62 A
----
logical_plan
01)Sort: pageviews DESC NULLS FIRST, fetch=10
02)--Projection: hits.Title, count(Int64(1)) AS count(*) AS pageviews
02)--Projection: hits.Title, count(Int64(1)) AS pageviews
03)----Aggregate: groupBy=[[hits.Title]], aggr=[[count(Int64(1))]]
04)------SubqueryAlias: hits
05)--------Projection: hits_raw.Title
Expand Down Expand Up @@ -1036,7 +1036,7 @@ EXPLAIN SELECT "URL", COUNT(*) AS PageViews FROM hits WHERE "CounterID" = 62 AND
logical_plan
01)Limit: skip=1000, fetch=10
02)--Sort: pageviews DESC NULLS FIRST, fetch=1010
03)----Projection: hits.URL, count(Int64(1)) AS count(*) AS pageviews
03)----Projection: hits.URL, count(Int64(1)) AS pageviews
04)------Aggregate: groupBy=[[hits.URL]], aggr=[[count(Int64(1))]]
05)--------SubqueryAlias: hits
06)----------Projection: hits_raw.URL
Expand Down Expand Up @@ -1065,7 +1065,7 @@ EXPLAIN SELECT "TraficSourceID", "SearchEngineID", "AdvEngineID", CASE WHEN ("Se
logical_plan
01)Limit: skip=1000, fetch=10
02)--Sort: pageviews DESC NULLS FIRST, fetch=1010
03)----Projection: hits.TraficSourceID, hits.SearchEngineID, hits.AdvEngineID, CASE WHEN hits.SearchEngineID = Int64(0) AND hits.AdvEngineID = Int64(0) THEN hits.Referer ELSE Utf8("") END AS src, hits.URL AS dst, count(Int64(1)) AS count(*) AS pageviews
03)----Projection: hits.TraficSourceID, hits.SearchEngineID, hits.AdvEngineID, CASE WHEN hits.SearchEngineID = Int64(0) AND hits.AdvEngineID = Int64(0) THEN hits.Referer ELSE Utf8("") END AS src, hits.URL AS dst, count(Int64(1)) AS pageviews
04)------Aggregate: groupBy=[[hits.TraficSourceID, hits.SearchEngineID, hits.AdvEngineID, CASE WHEN hits.SearchEngineID = Int16(0) AND hits.AdvEngineID = Int16(0) THEN hits.Referer ELSE Utf8View("") END AS CASE WHEN hits.SearchEngineID = Int64(0) AND hits.AdvEngineID = Int64(0) THEN hits.Referer ELSE Utf8("") END, hits.URL]], aggr=[[count(Int64(1))]]
05)--------SubqueryAlias: hits
06)----------Projection: hits_raw.URL, hits_raw.Referer, hits_raw.TraficSourceID, hits_raw.SearchEngineID, hits_raw.AdvEngineID
Expand Down Expand Up @@ -1094,7 +1094,7 @@ EXPLAIN SELECT "URLHash", "EventDate", COUNT(*) AS PageViews FROM hits WHERE "Co
logical_plan
01)Limit: skip=100, fetch=10
02)--Sort: pageviews DESC NULLS FIRST, fetch=110
03)----Projection: hits.URLHash, hits.EventDate, count(Int64(1)) AS count(*) AS pageviews
03)----Projection: hits.URLHash, hits.EventDate, count(Int64(1)) AS pageviews
04)------Aggregate: groupBy=[[hits.URLHash, hits.EventDate]], aggr=[[count(Int64(1))]]
05)--------SubqueryAlias: hits
06)----------Projection: hits_raw.URLHash, CAST(CAST(hits_raw.EventDate AS Int32) AS Date32) AS EventDate
Expand Down Expand Up @@ -1124,7 +1124,7 @@ EXPLAIN SELECT "WindowClientWidth", "WindowClientHeight", COUNT(*) AS PageViews
logical_plan
01)Limit: skip=10000, fetch=10
02)--Sort: pageviews DESC NULLS FIRST, fetch=10010
03)----Projection: hits.WindowClientWidth, hits.WindowClientHeight, count(Int64(1)) AS count(*) AS pageviews
03)----Projection: hits.WindowClientWidth, hits.WindowClientHeight, count(Int64(1)) AS pageviews
04)------Aggregate: groupBy=[[hits.WindowClientWidth, hits.WindowClientHeight]], aggr=[[count(Int64(1))]]
05)--------SubqueryAlias: hits
06)----------Projection: hits_raw.WindowClientWidth, hits_raw.WindowClientHeight
Expand Down Expand Up @@ -1153,7 +1153,7 @@ EXPLAIN SELECT DATE_TRUNC('minute', to_timestamp_seconds("EventTime")) AS M, COU
logical_plan
01)Limit: skip=1000, fetch=10
02)--Sort: date_trunc(Utf8("minute"), m) ASC NULLS LAST, fetch=1010
03)----Projection: date_trunc(Utf8("minute"),to_timestamp_seconds(hits.EventTime)) AS m, count(Int64(1)) AS count(*) AS pageviews
03)----Projection: date_trunc(Utf8("minute"),to_timestamp_seconds(hits.EventTime)) AS m, count(Int64(1)) AS pageviews
04)------Aggregate: groupBy=[[date_trunc(Utf8("minute"), to_timestamp_seconds(hits.EventTime))]], aggr=[[count(Int64(1))]]
05)--------SubqueryAlias: hits
06)----------Projection: hits_raw.EventTime
Expand Down
4 changes: 2 additions & 2 deletions datafusion/sqllogictest/test_files/count_star_rule.slt
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ query TT
EXPLAIN SELECT t1.a, COUNT() AS cnt FROM t1 GROUP BY t1.a HAVING COUNT() > 0;
----
logical_plan
01)Projection: t1.a, count(Int64(1)) AS count() AS cnt
01)Projection: t1.a, count(Int64(1)) AS cnt
02)--Filter: count(Int64(1)) > Int64(0)
03)----Aggregate: groupBy=[[t1.a]], aggr=[[count(Int64(1))]]
04)------TableScan: t1 projection=[a]
Expand All @@ -78,7 +78,7 @@ query TT
EXPLAIN SELECT a, COUNT() OVER (PARTITION BY a) AS count_a FROM t1;
----
logical_plan
01)Projection: t1.a, count(Int64(1)) PARTITION BY [t1.a] ROWS BETWEEN UNBOUNDED PRECEDING AND UNBOUNDED FOLLOWING AS count() PARTITION BY [t1.a] ROWS BETWEEN UNBOUNDED PRECEDING AND UNBOUNDED FOLLOWING AS count_a
01)Projection: t1.a, count(Int64(1)) PARTITION BY [t1.a] ROWS BETWEEN UNBOUNDED PRECEDING AND UNBOUNDED FOLLOWING AS count_a
02)--WindowAggr: windowExpr=[[count(Int64(1)) PARTITION BY [t1.a] ROWS BETWEEN UNBOUNDED PRECEDING AND UNBOUNDED FOLLOWING]]
03)----TableScan: t1 projection=[a]
physical_plan
Expand Down
4 changes: 2 additions & 2 deletions datafusion/sqllogictest/test_files/date_bin_errors.slt
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ select date_bin(interval '1637426858 months', to_timestamp_millis(1040292460), t
----
NULL

# Negative timestamp with month interval - should return NULL instead of panicking
# Negative timestamp with month interval - should return NULL instead of panicking
query P
select date_bin(interval '1 month', to_timestamp_millis(-1040292460), timestamp '1984-01-07 00:00:00');
----
Expand Down Expand Up @@ -57,4 +57,4 @@ select date_bin(
timestamp '1984-01-07 00:00:00'
) as b;
----
NULL
NULL
7 changes: 6 additions & 1 deletion datafusion/sqllogictest/test_files/encrypted_parquet.slt
Original file line number Diff line number Diff line change
Expand Up @@ -85,5 +85,10 @@ float_field float
)
STORED AS PARQUET LOCATION 'test_files/scratch/encrypted_parquet/'

query error DataFusion error: Parquet error: Parquet error: Parquet file has an encrypted footer but decryption properties were not provided
query RR
SELECT * FROM parquet_table
----
-1 -1
1 2
3 4
5 6
2 changes: 1 addition & 1 deletion datafusion/sqllogictest/test_files/group_by.slt
Original file line number Diff line number Diff line change
Expand Up @@ -5634,7 +5634,7 @@ physical_plan
statement ok
reset datafusion.execution.batch_size;

# The SLT runner sets `target_partitions` to 4 instead of using the default, so
# The SLT runner sets `target_partitions` to 4 instead of using the default, so
# reset it explicitly.
statement ok
set datafusion.execution.target_partitions = 4;
Expand Down
2 changes: 1 addition & 1 deletion datafusion/sqllogictest/test_files/information_schema.slt
Original file line number Diff line number Diff line change
Expand Up @@ -889,7 +889,7 @@ show functions
statement ok
reset datafusion.catalog.information_schema;

# The SLT runner sets `target_partitions` to 4 instead of using the default, so
# The SLT runner sets `target_partitions` to 4 instead of using the default, so
# reset it explicitly.
statement ok
set datafusion.execution.target_partitions = 4;
Expand Down
Loading
Loading