datafusion icon indicating copy to clipboard operation
datafusion copied to clipboard

Add standalone example of using the SQL frontend

Open alamb opened this issue 1 year ago • 3 comments

Which issue does this PR close?

Part of https://github.com/apache/datafusion/issues/10855

Rationale for this change

The current rewrite_expr.rs example has three distinct examples:

  1. Using DataFusion LogicalPlanning without execution
  2. Implementing an AnalyzerRule
  3. Implementing an OptimizerRule

Each I think should be its own example to make them easier to find and more full featured

What changes are included in this PR?

  1. Add example sql_frontend.rs
  2. Improve documentation of TableSource trait

Are these changes tested?

Yes by CI

Are there any user-facing changes?

alamb avatar Jun 23 '24 20:06 alamb

@andygrove or @jdye64 I wonder if you might have some time to review this PR as I think it is relevant to to your use of DataFusion

alamb avatar Jun 23 '24 22:06 alamb

I am working on getting the CI to run successfully on this PR, see https://github.com/apache/datafusion/pull/11173

alamb avatar Jun 28 '24 21:06 alamb

🤔 this might also make https://github.com/apache/datafusion/blob/main/datafusion/sql/examples/sql.rs redundant

alamb avatar Jun 28 '24 21:06 alamb

Thanks everyone for the comments and feedback

alamb avatar Jul 02 '24 20:07 alamb