Skip to content

Commit adfec24

Browse files
Merge remote-tracking branch 'datafusion/main'
2 parents ab8acf9 + 3911f0c commit adfec24

75 files changed

Lines changed: 5184 additions & 1930 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

Cargo.lock

Lines changed: 0 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

datafusion/core/benches/sql_planner.rs

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,8 @@ fn register_clickbench_hits_table(rt: &Runtime) -> SessionContext {
130130
format!("{BENCHMARKS_PATH_2}{CLICKBENCH_DATA_PATH}")
131131
};
132132

133-
let sql = format!("CREATE EXTERNAL TABLE hits STORED AS PARQUET LOCATION '{path}'");
133+
let sql =
134+
format!("CREATE EXTERNAL TABLE hits_raw STORED AS PARQUET LOCATION '{path}'");
134135

135136
// ClickBench partitioned dataset was written by an ancient version of pyarrow that
136137
// that wrote strings with the wrong logical type. To read it correctly, we must
@@ -139,6 +140,17 @@ fn register_clickbench_hits_table(rt: &Runtime) -> SessionContext {
139140
.unwrap();
140141
rt.block_on(ctx.sql(&sql)).unwrap();
141142

143+
// ClickBench stores EventDate as UInt16 (days since 1970-01-01). Create a view
144+
// that exposes it as SQL DATE so that queries comparing it with date literals
145+
// (e.g. "EventDate >= '2013-07-01'") work correctly during planning.
146+
rt.block_on(ctx.sql(
147+
"CREATE VIEW hits AS \
148+
SELECT * EXCEPT (\"EventDate\"), \
149+
CAST(CAST(\"EventDate\" AS INTEGER) AS DATE) AS \"EventDate\" \
150+
FROM hits_raw",
151+
))
152+
.unwrap();
153+
142154
let count =
143155
rt.block_on(async { ctx.table("hits").await.unwrap().count().await.unwrap() });
144156
assert!(count > 0);

datafusion/core/tests/memory_limit/mod.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -213,6 +213,7 @@ async fn sort_merge_join_spill() {
213213
.with_config(config)
214214
.with_disk_manager_builder(DiskManagerBuilder::default())
215215
.with_scenario(Scenario::AccessLogStreaming)
216+
.with_expected_success()
216217
.run()
217218
.await
218219
}

0 commit comments

Comments
 (0)