drill-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Arjun kr <arjun...@outlook.com>
Subject Re: About Drill Timezone Parse
Date Fri, 06 Apr 2018 08:59:31 GMT
Hi Alican,


Please see if below syntax helps. Looks like hour format is in 24-hour format (HH instead
of hh).


0: jdbc:drill:schema=dfs> select TO_TIMESTAMP('Mon June 04 12:09:56 EET 2001', 'E MMM dd
HH:mm:ss ZZZ yyyy') from (values(1));
+------------------------+
|         EXPR$0         |
+------------------------+
| 2001-06-04 12:09:56.0  |
+------------------------+
1 row selected (0.285 seconds)


Thanks,

Arjun



________________________________
From: Alican ERTURK <Alican.ERTURK@enerjisa.com>
Sent: Friday, April 6, 2018 12:35 PM
To: user@drill.apache.org
Subject: About Drill Timezone Parse


Hi,



I try to parse timestamp field in Apache Drill .



Our timestamp field format is :  'Wed June 04 12:09:56 EET 2001'



We use this parse function  -->  TO_TIMESTAMP('Wed June 04 12:09:56 EET 2001', 'E MMMM
dd hh:mm:ss z yyyy')  does not work.  We get an error as below :



--- org.apache.drill.common.exceptions.UserRemoteException: SYSTEM ERROR: IllegalArgumentException:
Invalid format: "Wed June 04 12:09:56 EET 2001" is malformed at "EET 2001" ---



However we change the timezone part EET to EST - TO_TIMESTAMP('Wed June 04 12:09:56 EST 2001',
'E MMMM dd hh:mm:ss z yyyy')   - it works. It parses the timestamp field.



How can we parse EET timezone format in Apache Drill ?



Can you help us ?



Best regards,







ALİCAN ERTÜRK
İŞ ZEKASI UZMANI
MİMARİ VE İŞ ZEKASI MÜDÜRLÜĞÜ
ENERJİSA ENERJİ A.Ş.



[Açıklama: cid:image005.png@01D1292C.496C01D0]






________________________________

Bu ileti hukuken korunmuş, gizli veya ifşa edilmemesi gereken bilgiler içerebilir. Şayet
mesajın gönderildiği kişi değilseniz, bu iletiyi çoğaltmak ve dağıtmak yasaktır.
Bu mesajı yanlışlıkla alan kişi, bu durumu derhal gönderene telefonla ya da e-posta
ile bildirmeli ve bilgisayarından silmelidir. Bu iletinin içeriğinden yalnızca iletiyi
gönderen kişi sorumludur.

This communication may contain information that is legally privileged, confidential or exempt
from disclosure. If you are not the intended recipient, please note that any dissemination,
distribution, or copying of this communication is strictly prohibited. Anyone who receives
this message in error should notify the sender immediately by telephone or by return communication
and delete it from his or her computer. Only the person who has sent this message is responsible
for its content.

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