drill-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Vitalii Diravka <vitalii.dira...@gmail.com>
Subject Re: Issue with time zone
Date Thu, 14 Dec 2017 13:10:55 GMT
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));
+--------------------------------------+
|                EXPR$0                |
+--------------------------------------+
| 2017-12-14 12:42:44.508 Europe/Kiev  |
+--------------------------------------+
1 row selected (0.332 seconds)

Kind regards
Vitalii

On Thu, Dec 14, 2017 at 1:36 PM, Vova Vysotskyi <vvovyk@gmail.com> wrote:

> 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','YYYY-MM-dd HH:mm:ss') from sys.version;
> Error: SYSTEM ERROR: IllegalInstantException: Cannot parse "2015-03-08
> 02:58:51": Illegal instant due to time zone offset transition
> (America/New_York)
>
> 2) When I set the timezone in drill-env.sh using
> export DRILL_JAVA_OPTS="-Duser.timezone=UTC"
> timezone is set correctly, and the query returned the correct result:
> 0: jdbc:drill:zk=local> select to_timestamp('2015-03-08
> 02:58:51','YYYY-MM-dd HH:mm:ss') from sys.version;
> +------------------------+
> |         EXPR$0         |
> +------------------------+
> | 2015-03-08 02:58:51.0  |
> +------------------------+
> 1 row selected (1.697 seconds)
>
> Perhaps, you have used the wrong character instead of the double quote at
> the end of the export string.
> Please confirm if this helped to avoid this issue.
>
> When I set the timezone in drill-env.sh, it was seen with ps.
>
> Option user.timezone was deleted from drill options, so you could not see
> it when running select * from sys.options where name like '%timezone%'
>
> Also, drillbit could not be started on a local computer without zookeeper.
>
>
>
> 2017-12-13 18:53 GMT+02:00 Kostyantyn Krakovych <kkrakovych@icloud.com>:
>
> > Hi Team,
> >
> > I faced with the issue described in http://www.openkb.info/2015/
> > 05/understanding-drills-timestamp-and.html <http://www.openkb.info/2015/
> > 05/understanding-drills-timestamp-and.html>
> >
> > Drill 1.11
> >
> > I run sqlline -u jdbc:drill:zk=local on local computer.
> > Meantime I do not see user.timestamp option neither in sys.options nor in
> > sys.boot.
> > And the issue is not resolved when I set the parameter in drill-env.sh as
> > export DRILL_JAVA_OPTS="-Duser.timezone=UTC”
> > I do not see the option with ps -ef.
> >
> > N.B. I do not start drillbit. Though for the tool I confirm I see
> > -Duser.timestamp=UTC with ps -ef | grep “user.timestamp” IF I start it,
> so
> > it fails with other reason on local computer (Failure to connect to the
> > zookeeper cluster service within the allotted time of 10000
> milliseconds.).
> >
> > Could you please advice on the issue.
> >
> >
> > Best regards,
> > Kostyantyn
>
>
>
>
> --
> Kind regards,
> Volodymyr Vysotskyi
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message