Re: Building a LogicalPlan

2016-12-02 Thread Paul Rogers
Have you considered something like JOOQ [1] to generate SQL for you, then just use Drill’s SQL support? I’ve not used JOOQ, but I’ve used similar approaches in past projects. - Paul [1] http://www.jooq.org > On Dec 2, 2016, at 7:20 AM, Aman Sinha wrote: > >

Re: Building a LogicalPlan

2016-12-02 Thread Aman Sinha
Unfortunately, the 'LogicalPlan' structure that is created by the LogicalPlanBuilder does not go through the full Drill query optimization process. You are better off starting with a Calcite Rel and then building a Drill logical plan with 'Rels' (e.g DrillFilterRel, DrillProjectRel etc.). On

Re: Building a LogicalPlan

2016-12-02 Thread Ted Dunning
It might be easier to start by stealing a plan from a normal SQL query and then trying to build that. Not that this is a long-term solution, but it gets you going with the many unstated assumptions about a plan that might be present. That would give you something in JSON, however, rather than

Building a LogicalPlan

2016-12-01 Thread Chris Baynes
Hi, We have a use case in which we want to construct queries programmatically which Drill would then execute. So far I've been able to configure a Jdbc StorageEngine, and initialize a LogicalPlan (using the builder) with that. I am having difficulty trying to configure scan, project, and