Vineet Garg created HIVE-20340:
----------------------------------

             Summary: Druid Needs Explicit CASTs from Timestamp to STRING when 
the output of timestamp function is used as String
                 Key: HIVE-20340
                 URL: https://issues.apache.org/jira/browse/HIVE-20340
             Project: Hive
          Issue Type: Bug
          Components: Druid integration
            Reporter: Vineet Garg
            Assignee: Vineet Garg


Druid time expressions return numeric values in form of ms (instead of 
formatted timestamp). Because of this expressions/function which expects its 
argument as string type ended up returning different values for time 
expressions input.

e.g. 
{code}
SELECT SUBSTRING(to_date(datetime0),4) FROM tableau_orc.calcs;
| 4-07-25  |

SELECT SUBSTRING(to_date(datetime0),4) FROM druid_tableau.calcs;
| 0022400000  |

SELECT CONCAT(to_date(datetime0),' 00:00:00') FROM tableau_orc.calcs;
| 2004-07-17 00:00:00  |

SELECT CONCAT(to_date(datetime0),' 00:00:00') FROM druid_tableau.calcs;
| 1090454400000 00:00:00  |
 {code}

Druid needs explicit cast to make this work



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to