Can anyone helpout with the TIMESTAMP literals piece. So far, I've gotten Select day_timestamp from lu_day where day_timestamp > to_utc_timestamp('2012-06-04 00:00:00', 'GMT') to work ok and give me back timestamps greater than the one in the literal. Is this the best function to get this to work or is there something else I should be using
From: Ladda, Anand Sent: Monday, May 28, 2012 11:00 AM To: user@hive.apache.org Subject: RE: FW: Filtering on TIMESTAMP data type Debarshi Didn't quite follow your first comment. I get the write-your-own UDF part but was wondering how others have been transitioning from STRING dates to TIMESTAMP dates and getting filtering, partition pruning, etc to work with constants -Anand From: Debarshi Basak [mailto:debarshi.ba...@tcs.com] Sent: Saturday, May 26, 2012 11:54 AM To: user@hive.apache.org<mailto:user@hive.apache.org> Subject: Re: FW: Filtering on TIMESTAMP data type I guess it exist gotta check. btw...You can always go and write a udf Debarshi Basak Tata Consultancy Services Mailto: debarshi.ba...@tcs.com<mailto:debarshi.ba...@tcs.com> Website: http://www.tcs.com ____________________________________________ Experience certainty. IT Services Business Solutions Outsourcing ____________________________________________ -----"Ladda, Anand" wrote: ----- To: "user@hive.apache.org<mailto:user@hive.apache.org>" <user@hive.apache.org<mailto:user@hive.apache.org>>, "d...@hive.apache.org<mailto:d...@hive.apache.org>" <d...@hive.apache.org<mailto:d...@hive.apache.org>> From: "Ladda, Anand" <lan...@microstrategy.com<mailto:lan...@microstrategy.com>> Date: 05/26/2012 06:58PM Subject: FW: Filtering on TIMESTAMP data type How do I set-up a filter constant for TIMESTAMP datatype. In Hive 0.7 since timestamps were represented as strings a query like this would return data select * from LU_day where day_date ='2010-01-01 00:00:00'; But now with day_date as a TIMESTAMP column it doesn't. Is there some type of a TO_TIMESTAMP function in hive to convert the string constant into a TIMESTAMP one As a workaround I can do select * from LU_DAY where TO_DATE(day_date) = '2010-01-01' but that would be a problem for partitioning pruning, etc =====-----=====-----===== Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you