drill-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Khurram Faraaz <kfar...@maprtech.com>
Subject cast to date - different result on sqlline vs on Web UI
Date Wed, 14 Dec 2016 03:20:44 GMT
Hi All,

I am on Drill 1.9.0 git commit ID: 51246693
Why does Drill return different result on sqlline vs when run on Web UI ?

{noformat}
postgres=# SELECT (CASE WHEN (false) THEN null ELSE cast('2016/09/22' as
date) END) res1 FROM (VALUES(1)) subquery;

    res1

------------

 2016-09-22

(1 row)

{noformat}
This is from sqlline prompt

0: jdbc:drill:schema=dfs.tmp> SELECT (CASE WHEN (false) THEN null ELSE
cast('2016/09/22' as date) END) res1 FROM (VALUES(1)) subquery;

*+-------------+*

*| **   res1    ** |*

*+-------------+*

*| *2016-09-22 * |*

*+-------------+*

1 row selected (0.336 seconds)


However from Drill's Web UI, we get a different result note the T00:00:00.000Z,
at the end of date string.

SELECT (CASE WHEN (false) THEN null ELSE cast('2016/09/22' as date) END)
res1 FROM (VALUES(1)) subquery;

res1

2016-09-22T00:00:00.000Z

Thanks,
Khurram

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