Re: Issue with time zone

2017-12-14 Thread Vitalii Diravka
Hi Kostyantyn, * Without zookeeper you can just run drillbit in embedded mode: *bin/drill-embedded* * Also "*timeofday()*" Drill function can help you to identify a timezone used by your drillbit: "start your sql engine" 0: jdbc:drill:zk=local> SELECT TIMEOFDAY() FROM (VALUES(1));

Re: Issue with time zone

2017-12-14 Thread Vova Vysotskyi
Hi Kostyantyn, I just checked this issue: 1) With timezone America/New_York query fails as it was described: 0: jdbc:drill:zk=local> select to_timestamp('2015-03-08 02:58:51','-MM-dd HH:mm:ss') from sys.version; Error: SYSTEM ERROR: IllegalInstantException: Cannot parse "2015-03-08 02:58:51":

Re: [1.9.0] : UserException: SYSTEM ERROR: IllegalReferenceCountException: refCnt: 0 and then SYSTEM ERROR: IOException: Failed to shutdown streamer

2017-12-14 Thread Anup Tiwari
Hi Kunal, Please find below answers to your question :- 1. Setup description :- Number of Nodes : 5 RAM/Node : 32GB Core/Node : 8 DRILL_MAX_DIRECT_MEMORY="20G" DRILL_HEAP="16G" 2. What queries were you running and against what kind of dataset :- Same type of queries as mentioned in trail mail

Re: Illegal Argument Exception while convert unix date format to drill timestamp

2017-12-14 Thread Vova Vysotskyi
Hi Divya, Default timestamp format for Drill is '-MM-DD HH:MI:SS'. For the cases, when you want to get a timestamp from a string with another format, date pattern should be specified. Drill allows using both Jodatime patterns (to_date, to_time, to_timestamp functions, see allowed patterns at

Re: Drill session and jdbc connections

2017-12-14 Thread Prasad Nagaraj Subramanya
The code looks good. To keep things simple you can call *reset `option_name`* for all options which you change during the session. (that way you need not be concerned with the default value) So, your finally block will look like - finally{ st.executeQuery("RESET `store.format`");

Re: Drill session and jdbc connections

2017-12-14 Thread Rahul Raj
Let me know if the code is fine. Regards, Rahul On Thu, Dec 14, 2017 at 1:53 PM, Rahul Raj wrote: > Sorry, I confused. I am using a pool of connections, code snippet below: > > try(Connection conn = pool.getConnection()){ > try(Statement st =

Re: Drill session and jdbc connections

2017-12-14 Thread Rahul Raj
Sorry, I confused. I am using a pool of connections, code snippet below: try(Connection conn = pool.getConnection()){ try(Statement st = conn.createStatement()){ try{ st.executeQuery("ALTER SESSION SET `store.format`='csv'"); ResultSet rs = st.executeQuery("CTAS HERE

Re: Illegal Argument Exception while convert unix date format to drill timestamp

2017-12-14 Thread Arjun kr
Pls see if this works for you. 0: jdbc:drill:schema=dfs> SELECT TO_TIMESTAMP('Sun Apr 1 00:00:01 UTC 2018', 'E MMM d HH:mm:ss z ') FROM (VALUES(1)); ++ | EXPR$0 | ++ | 2018-04-01 00:00:01.0 | ++ 1 row