RImpala_query: Function to run a Query in Impala

Description Usage Arguments Value Author(s) Examples

Description

This function executes the Query specified as an argument in Impala. If no query is passed, the show tables query is run as default

Usage

1
rimpala.query(Q="show tables",isDDL="false",fetchSize="10000")

Arguments

Q

The Query to be executed on Impala. The default query is show tables.

isDDL

Flag Parameter to indicate if the query is DDL - "true" / "false" ( Default: false)

fetchSize

Set the Number of rows to be retrieved with each Impala roundtrip call (Default : 10000)

Value

The result of the Query is returned into a dataframe if the Query is valid and does not have any errors.

Author(s)

Vijay Raajaa vijay.raajaa@mu-sigma.com,
Austin Chungath Vincent austin.cv@mu-sigma.com,
Vikas Raguttahalli vikas.r@mu-sigma.com,
Sachin Sudarshana sachin.sudarshana@mu-sigma.com

Examples

1
2
3
4
5
6
7
8
9
## Not run: 
library("RImpala")
rimpala.init()
rimpala.connect(IP="127.0.0.1",port="21050")
res = rimpala.query(Q="Select * from sample_table")
res = rimpala.query(Q="Select * from sample_table",fetchSize="10000")
rimpala.query(Q="drop table sample_table",isDDL="true")

## End(Not run)

RImpala documentation built on May 30, 2017, 4:09 a.m.