You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@drill.apache.org by Peder Jakobsen | gmail <pj...@gmail.com> on 2015/12/28 05:51:35 UTC

Learning to use the C++ client libraries

Hi,

Coming from the Python/Ruby /bash shell world, I find working SQLLine a
hard pill to swallow; it's it's very "DOS" like, aka almost featureless.
For this reason,  I'd like to explore writing a python wrapper around the
Drill C++ client libraries.  What's the best way to learn to use this
library? Is there a test suite I can run and study, perhaps with a bit of
documentation for each test?

Thanks,

Peder J.

Re: Learning to use the C++ client libraries

Posted by Parth Chandra <pa...@apache.org>.
If you still want to explore the C++ API, there is an example program at

contrib/native/client/example/querySubmitter.cpp

The REST API is probably much easier to use, though. One caveat is that if
a query returns a large data set, there is no pagination and you'll have to
deal with it in your application.





On Mon, Dec 28, 2015 at 7:19 AM, Peder Jakobsen | gmail <pjakobsen@gmail.com
> wrote:

> Great suggestion, that's exactly what I needed.  Thank you.
>
> Peder J.
>
> On Mon, Dec 28, 2015 at 8:00 AM, John Omernik <jo...@omernik.com> wrote:
>
> > +1 to the Rest API.  I've used that with Python and the "requests" and
> > "json" modules to great affect.
> >
> > On Sun, Dec 27, 2015 at 11:06 PM, Charles Givre <cg...@gmail.com>
> wrote:
> >
> > > Hi Peder,
> > > Have you experimented with the RESTful interface as well as the
> ODBC/JDBC
> > > connectivity features of Drill?  You can use those, and some common
> > python
> > > libraries to write scripts that interact with Drill.
> > >
> > > Here’s an iPython Notebook that demonstrates the RESTful interface and
> > > Drill.  (
> > >
> >
> https://github.com/cgivre/DS/blob/master/Querying%20Apache%20Drill%20via%20the%20RESTful%20Interface.ipynb
> > > )
> > >
> > > — C
> > >
> > > > On Dec 27, 2015, at 23:51, Peder Jakobsen | gmail <
> pjakobsen@gmail.com
> > >
> > > wrote:
> > > >
> > > > Hi,
> > > >
> > > > Coming from the Python/Ruby /bash shell world, I find working
> SQLLine a
> > > > hard pill to swallow; it's it's very "DOS" like, aka almost
> > featureless.
> > > > For this reason,  I'd like to explore writing a python wrapper around
> > the
> > > > Drill C++ client libraries.  What's the best way to learn to use this
> > > > library? Is there a test suite I can run and study, perhaps with a
> bit
> > of
> > > > documentation for each test?
> > > >
> > > > Thanks,
> > > >
> > > > Peder J.
> > >
> > >
> >
>

Re: Learning to use the C++ client libraries

Posted by Peder Jakobsen | gmail <pj...@gmail.com>.
Great suggestion, that's exactly what I needed.  Thank you.

Peder J.

On Mon, Dec 28, 2015 at 8:00 AM, John Omernik <jo...@omernik.com> wrote:

> +1 to the Rest API.  I've used that with Python and the "requests" and
> "json" modules to great affect.
>
> On Sun, Dec 27, 2015 at 11:06 PM, Charles Givre <cg...@gmail.com> wrote:
>
> > Hi Peder,
> > Have you experimented with the RESTful interface as well as the ODBC/JDBC
> > connectivity features of Drill?  You can use those, and some common
> python
> > libraries to write scripts that interact with Drill.
> >
> > Here’s an iPython Notebook that demonstrates the RESTful interface and
> > Drill.  (
> >
> https://github.com/cgivre/DS/blob/master/Querying%20Apache%20Drill%20via%20the%20RESTful%20Interface.ipynb
> > )
> >
> > — C
> >
> > > On Dec 27, 2015, at 23:51, Peder Jakobsen | gmail <pjakobsen@gmail.com
> >
> > wrote:
> > >
> > > Hi,
> > >
> > > Coming from the Python/Ruby /bash shell world, I find working SQLLine a
> > > hard pill to swallow; it's it's very "DOS" like, aka almost
> featureless.
> > > For this reason,  I'd like to explore writing a python wrapper around
> the
> > > Drill C++ client libraries.  What's the best way to learn to use this
> > > library? Is there a test suite I can run and study, perhaps with a bit
> of
> > > documentation for each test?
> > >
> > > Thanks,
> > >
> > > Peder J.
> >
> >
>

Re: Learning to use the C++ client libraries

Posted by John Omernik <jo...@omernik.com>.
+1 to the Rest API.  I've used that with Python and the "requests" and
"json" modules to great affect.

On Sun, Dec 27, 2015 at 11:06 PM, Charles Givre <cg...@gmail.com> wrote:

> Hi Peder,
> Have you experimented with the RESTful interface as well as the ODBC/JDBC
> connectivity features of Drill?  You can use those, and some common python
> libraries to write scripts that interact with Drill.
>
> Here’s an iPython Notebook that demonstrates the RESTful interface and
> Drill.  (
> https://github.com/cgivre/DS/blob/master/Querying%20Apache%20Drill%20via%20the%20RESTful%20Interface.ipynb
> )
>
> — C
>
> > On Dec 27, 2015, at 23:51, Peder Jakobsen | gmail <pj...@gmail.com>
> wrote:
> >
> > Hi,
> >
> > Coming from the Python/Ruby /bash shell world, I find working SQLLine a
> > hard pill to swallow; it's it's very "DOS" like, aka almost featureless.
> > For this reason,  I'd like to explore writing a python wrapper around the
> > Drill C++ client libraries.  What's the best way to learn to use this
> > library? Is there a test suite I can run and study, perhaps with a bit of
> > documentation for each test?
> >
> > Thanks,
> >
> > Peder J.
>
>

Re: Learning to use the C++ client libraries

Posted by Charles Givre <cg...@gmail.com>.
Hi Peder, 
Have you experimented with the RESTful interface as well as the ODBC/JDBC connectivity features of Drill?  You can use those, and some common python libraries to write scripts that interact with Drill.  

Here’s an iPython Notebook that demonstrates the RESTful interface and Drill.  (https://github.com/cgivre/DS/blob/master/Querying%20Apache%20Drill%20via%20the%20RESTful%20Interface.ipynb)

— C

> On Dec 27, 2015, at 23:51, Peder Jakobsen | gmail <pj...@gmail.com> wrote:
> 
> Hi,
> 
> Coming from the Python/Ruby /bash shell world, I find working SQLLine a
> hard pill to swallow; it's it's very "DOS" like, aka almost featureless.
> For this reason,  I'd like to explore writing a python wrapper around the
> Drill C++ client libraries.  What's the best way to learn to use this
> library? Is there a test suite I can run and study, perhaps with a bit of
> documentation for each test?
> 
> Thanks,
> 
> Peder J.