goldmedal commented on issue #10855:
URL: https://github.com/apache/datafusion/issues/10855#issuecomment-2158643791

   Currently, in my personal work, I just use it like
   ```rust
   let ctx = SessionContext::new();
   let new_state = ctx
       .state()
       .add_analyzer_rule(Arc::new(ModelAnalyzeRule::new()))
       .add_analyzer_rule(Arc::new(ModelGenerationRule::new()));
   let new_ctx = SessionContext::new_with_state(new_state);
   // create a plan to run a SQL query
   let df = new_ctx.sql("SELECT * FROM wrenai.default.orders").await?;
   ```
   After the API updated, I guess it would be
   ```rust
   let ctx = SessionContext::new();
   ctx.state()
       .add_analyzer_rule(Arc::new(ModelAnalyzeRule::new()))
       .add_analyzer_rule(Arc::new(ModelGenerationRule::new()));
   // create a plan to run a SQL query
   let df = ctx.sql("SELECT * FROM wrenai.default.orders").await?;
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org
For additional commands, e-mail: github-h...@datafusion.apache.org

Reply via email to