apache-drill

Exception in using bootstrap-storage-plugins.json file for storage plugin in apache-drill

别说谁变了你拦得住时间么 提交于 2019-12-24 13:19:41
问题 I want to add storage plugins for MongoDB in apache-drill . After reading docs, I came to know that programmatically I can do that in two ways: Rest API using bootstrap-storage-plugins.json for configuration I am using 2nd way for my java code. Useful portion of my code: Connection conn = new Driver().connect("jdbc:drill:zk=local",null); Statement stmt = conn.createStatement(); ResultSet rs = stmt.executeQuery("show databases"); while (rs.next()) { String SCHEMA_NAME = rs.getString("SCHEMA

If the apache Drill can execute update, delete ,insert operations

ⅰ亾dé卋堺 提交于 2019-12-24 01:54:56
问题 As we known that apache drill can easy to query , but I have some questions as followings : First : If the apache Drill can execute update, delete ,insert operations on HDFS . Second : If the first question's answer is yes , how can I use apache Drill to update, or to delete, or to insert data on HDFS . 回答1: Apache Drill cannot insert, update, or delete data that currently exists on HDFS. You can execute a Create Table AS (CTAS) statement to create a new data set. Some examples of its use are

How to write custom storage plugin for apache drill

元气小坏坏 提交于 2019-12-22 08:24:16
问题 I have my data in a propriety format, None of the ones supported by Apache drill. Are there any tutorial on how to write my own storage plugin to handle such data. 回答1: This is something that really should be in the docs but currently is not. The interface isn't too complicated, but it can be a bit much to look at one of the existing plugins and understand everything that is going on. There are 2 major components to writing a storage plugin, exposing information to the query planner and

Is it possible to read and write Parquet using Java without a dependency on Hadoop and HDFS?

故事扮演 提交于 2019-12-21 15:12:10
问题 I've been hunting around for a solution to this question. It appears to me that there is no way to embed reading and writing Parquet format in a Java program without pulling in dependencies on HDFS and Hadoop. Is this correct? I want to read and write on a client machine, outside of a Hadoop cluster. I started to get excited about Apache Drill, but it appears that it must run as a separate process. What I need is an in-process ability to read and write a file using the Parquet format. 回答1:

Is it possible to read and write Parquet using Java without a dependency on Hadoop and HDFS?

人盡茶涼 提交于 2019-12-21 15:10:11
问题 I've been hunting around for a solution to this question. It appears to me that there is no way to embed reading and writing Parquet format in a Java program without pulling in dependencies on HDFS and Hadoop. Is this correct? I want to read and write on a client machine, outside of a Hadoop cluster. I started to get excited about Apache Drill, but it appears that it must run as a separate process. What I need is an in-process ability to read and write a file using the Parquet format. 回答1:

How to Use Apache Drill with Cassandra

青春壹個敷衍的年華 提交于 2019-12-21 04:23:25
问题 I am trying to query Cassandra using Apache Drill. The only connector I could find is here: http://www.confusedcoders.com/bigdata/apache-drill/sql-on-cassandra-querying-cassandra-via-apache-drill However this does not build. It comes up with an artifact not found error. I also had another developer who is more versed in these tools take a stab at it, but he also had no luck. I tried contacting the developer of the plugin I referenced, but the blog does not work and won't let me post comments.

How to create connection in storage plugin of Apache Drill Programmatically in c#

痴心易碎 提交于 2019-12-18 09:27:45
问题 I want to add new connections in storage plugins through my code. Would you please tell how to add or configure connections in storage plugin programmatically in c# . Is it possible to configure storage plugin connection through command prompt? If yes, how? 回答1: I found out some solution for that: var request = (HttpWebRequest)WebRequest.Create(url); var postData = "name=" + name + "&config=" + config; var data = Encoding.ASCII.GetBytes(postData); request.Method = "POST"; request.ContentType

Write Drill query output to csv (or some other format)

半腔热情 提交于 2019-12-18 04:47:10
问题 I'm using drill in embedded mode, and I can't figure out how to save query output other than copy and pasting it. 回答1: If you're using sqlline, you can create a new table as CSV as follows: use dfs.tmp; alter session set `store.format`='csv'; create table dfs.tmp.my_output as select * from cp.`employee.json`; Your CSV file(s) will appear in /tmp/my_output. 回答2: You can specify !record <file_path> to save all output to particular file. Drill docs 回答3: If you are using SQLLINE use !record . If

Multi line command (to export .csv) not working in Apache Drill (web interface)

半城伤御伤魂 提交于 2019-12-13 03:43:29
问题 I am trying to use Apache Drill to export a .csv file. This other question indicated that this is achieved by: use dfs.tmp; alter session set `store.format`='csv'; create table dfs.tmp.my_output as select * from cp.`employee.json`; I tried running this block (of three commands) simultaneously in the Apache Drill web interface but got the error bellow. It somehow is not recognizing the ; or not taking multiple commands. I also tried running each line separately, without the ; but the changes

Value overflows specified precision 0 with scale 0

怎甘沉沦 提交于 2019-12-12 22:21:31
问题 I'm trying to create custom fuction for Apache Drill (v1.15). When using a Decimal as an output data type, it fails even with the simplest example. When using another data types (int, float ..), it works well. Is there any simple way, how to make decimals work as output of UDF? @FunctionTemplate( name = "testing_udf", scope = FunctionTemplate.FunctionScope.SIMPLE, nulls = FunctionTemplate.NullHandling.NULL_IF_NULL ) public class TestingUdfFunction implements DrillSimpleFunc { @Param