Skip to content

Apache DataFusion SQL Query Engine

Minor: Examples cleanup + more docs in pruning example (#11086)

Andrew Lambc7ac8b822122
diff --git a/datafusion-examples/README.md b/datafusion-examples/README.md
index 0446a00818..f7f98c1d2a 100644
--- a/datafusion-examples/README.md
+++ b/datafusion-examples/README.md
@@ -62,10 +62,10 @@ cargo run --example csv_sql
- [`function_factory.rs`](examples/function_factory.rs): Register `CREATE FUNCTION` handler to implement SQL macros
- [`make_date.rs`](examples/make_date.rs): Examples of using the make_date function
- [`memtable.rs`](examples/memtable.rs): Create an query data in memory using SQL and `RecordBatch`es
-- ['parquet_index.rs'](examples/parquet_index.rs): Create an secondary index over several parquet files and use it to speed up queries
+- [`parquet_index.rs`](examples/parquet_index.rs): Create an secondary index over several parquet files and use it to speed up queries
- [`parquet_sql.rs`](examples/parquet_sql.rs): Build and run a query plan from a SQL statement against a local Parquet file
- [`parquet_sql_multiple_files.rs`](examples/parquet_sql_multiple_files.rs): Build and run a query plan from a SQL statement against multiple local Parquet files
-- ['parquet_exec_visitor.rs'](examples/parquet_exec_visitor.rs): Extract statistics by visiting an ExecutionPlan after execution
+- [`parquet_exec_visitor.rs`](examples/parquet_exec_visitor.rs): Extract statistics by visiting an ExecutionPlan after execution
- [`parse_sql_expr.rs`](examples/parse_sql_expr.rs): Parse SQL text into Datafusion `Expr`.
- [`plan_to_sql.rs`](examples/plan_to_sql.rs): Generate SQL from Datafusion `Expr` and `LogicalPlan`
- [`pruning.rs`](examples/parquet_sql.rs): Use pruning to rule out files based on statistics
diff --git a/datafusion-examples/examples/pruning.rs b/datafusion-examples/examples/pruning.rs
index 3fa35049a8..c090cd2bcc 100644
--- a/datafusion-examples/examples/pruning.rs
+++ b/datafusion-examples/examples/pruning.rs
@@ -33,6 +33,11 @@ use std::sync::Arc;
/// quickly eliminate entire files / partitions / row groups of data from
/// consideration using statistical information from a catalog or other
/// metadata.
+///
+/// This example uses a user defined catalog to supply pruning information, as
+/// one might do as part of a higher level storage engine. See
+/// `parquet_index.rs` for an example that uses pruning in the context of an
+/// individual query.
#[tokio::main]
async fn main() {
// In this example, we'll use the PruningPredicate to determine if