Skip to content

Commit ed718c0

Browse files
committed
fix page_index_filter_one_col and remove an example of proto
1 parent 63c2ebc commit ed718c0

File tree

3 files changed

+3
-25
lines changed

3 files changed

+3
-25
lines changed

datafusion/core/tests/parquet/page_pruning.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,8 @@ async fn page_index_filter_one_col() {
160160

161161
// 5.create filter date_string_col == "01/01/09"`;
162162
// Note this test doesn't apply type coercion so the literal must match the actual view type
163-
let filter = col("date_string_col").eq(lit(ScalarValue::new_utf8view("01/01/09")));
163+
// xudong: use new_utf8, because schema_force_view_types was changed to false now.
164+
let filter = col("date_string_col").eq(lit(ScalarValue::new_utf8("01/01/09")));
164165
let parquet_exec = get_parquet_exec(&state, filter).await;
165166
let mut results = parquet_exec.execute(0, task_ctx.clone()).unwrap();
166167
let batch = results.next().await.unwrap().unwrap();

datafusion/proto/src/lib.rs

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -97,29 +97,6 @@
9797
//! assert_eq!(format!("{:?}", plan), format!("{:?}", logical_round_trip));
9898
//! # Ok(())
9999
//! # }
100-
//! ```
101-
//! # Example: Serializing [`ExecutionPlan`]s
102-
//!
103-
//! ```
104-
//! # use datafusion::prelude::*;
105-
//! # use datafusion_common::Result;
106-
//! # use datafusion_proto::bytes::{physical_plan_from_bytes,physical_plan_to_bytes};
107-
//! # #[tokio::main]
108-
//! # async fn main() -> Result<()>{
109-
//! // Create a plan that scans table 't'
110-
//! let ctx = SessionContext::new();
111-
//! ctx.register_csv("t1", "tests/testdata/test.csv", CsvReadOptions::default()).await?;
112-
//! let physical_plan = ctx.table("t1").await?.create_physical_plan().await?;
113-
//!
114-
//! // Convert the plan into bytes (for sending over the network, etc.)
115-
//! let bytes = physical_plan_to_bytes(physical_plan.clone())?;
116-
//!
117-
//! // Decode bytes from somewhere (over network, etc.) back to ExecutionPlan
118-
//! let physical_round_trip = physical_plan_from_bytes(&bytes, &ctx)?;
119-
//! assert_eq!(format!("{:?}", physical_plan), format!("{:?}", physical_round_trip));
120-
//! # Ok(())
121-
//! # }
122-
//! ```
123100
pub mod bytes;
124101
pub mod common;
125102
pub mod generated;

datafusion/sqllogictest/test_files/limit.slt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -854,7 +854,7 @@ physical_plan
854854
02)--SortExec: TopK(fetch=1000), expr=[part_key@1 ASC NULLS LAST], preserve_partitioning=[false]
855855
03)----ProjectionExec: expr=[1 as foo, part_key@0 as part_key]
856856
04)------CoalescePartitionsExec: fetch=1
857-
05)--------DataSourceExec: file_groups={3 groups: [[WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/parquet/test_limit_with_partitions/part-1.parquet:0..265], [WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/parquet/test_limit_with_partitions/part-1.parquet:265..530], [WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/parquet/test_limit_with_partitions/part-1.parquet:530..794]]}, projection=[part_key], limit=1, file_type=parquet
857+
05)--------DataSourceExec: file_groups={3 groups: [[WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/parquet/test_limit_with_partitions/part-2.parquet:0..265], [WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/parquet/test_limit_with_partitions/part-2.parquet:265..530], [WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/parquet/test_limit_with_partitions/part-2.parquet:530..794]]}, projection=[part_key], limit=1, file_type=parquet
858858

859859
query I
860860
with selection as (

0 commit comments

Comments
 (0)