You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@arrow.apache.org by "Jorge (Jira)" <ji...@apache.org> on 2020/02/06 20:28:00 UTC

[jira] [Created] (ARROW-7787) Add collect to Table API

Jorge created ARROW-7787:
----------------------------

             Summary: Add collect to Table API
                 Key: ARROW-7787
                 URL: https://issues.apache.org/jira/browse/ARROW-7787
             Project: Apache Arrow
          Issue Type: Improvement
          Components: Rust - DataFusion
            Reporter: Jorge


Currently, executing using the table API requires some effort: given a table `t`:

 
{code:java}
plan = t.to_logical_plan()
plan = ctx.optimize(plan)
plan = ctx.create_physical_plan(plan, batch_size)
result = ctx.collect(plan)
{code}
This issue proposes a 2 new public methods, one for Table,

 
{code:java}
fn collect(&self, ctx: &mut ExecutionContext, batch_size: usize) -> Result<Vec<RecordBatch>>;
{code}
and one for ExecutionContext,
{code:java}
pub fn collect_plan(&mut self, plan: &LogicalPlan, batch_size: usize) -> Result<Vec<RecordBatch>>
{code}
that optimize, execute and collect the results of the Table/LogicalPlan respectively, in the same spirit of `ExecutionContext.sql`.

 

 

 



--
This message was sent by Atlassian Jira
(v8.3.4#803005)