hive-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bejoy Ks <bejoy...@yahoo.com>
Subject Re: How to add hours/minutes to a timestamp column in Hive Query
Date Thu, 24 Feb 2011 14:27:10 GMT
Hi Experts
      Could some one please help me out with this? Any similar situations faced 
by any one in your real time hive queries?
If I have to go ahead with an User Defined Function for this, then how could I 
implement and use the same in Hive?
Does Hive have any plans/JIRAs in progress with this functionality 
implementation.

Thank You

Regards
Bejoy K S




________________________________
From: Bejoy Ks <bejoy_ks@yahoo.com>
To: user@hive.apache.org
Sent: Wed, February 23, 2011 5:19:10 PM
Subject: How to add hours/minutes to a timestamp column in Hive Query


Hi 
    Is there any function in hive with which we can add hours/minutes to a given 
stamp. 

Say I have a timestamp oriented column 'Arrival_Time', to do some database 
oriented calculations i have to add 4 hours to the 'Arrival_Time' in my Hive 
Query. How do I accomplish this? I have see in hive documentation that we can 
use the date_add(string startdate, int days) method to add days to a date. Any 
similar methods for time stamps to add hours?

Regards
Bejoy KS


      
Mime
View raw message