Mark - I see your discussion with Mr. Harris here:
https://issues.apache.org/jira/browse/HIVE-3822
I agree that the result of the from_unixtime() function would return the ts
based on the system time, but and struggling with the cast(int as
timestamp) returning a value affected by the system time
So I read that JIRA, and also found this linked JIRA:
https://issues.apache.org/jira/browse/HIVE-3454
So I decided to try the * 1.0 work around.
select
starttime,
from_unixtime(starttime) as unixtime,
cast((starttime * 1.0) as timestamp) as castts,
from_utc_timestamp(starttime * 1.0, 'GMT') as
Brad is correct, there is a JIRA about this already:
https://issues.apache.org/jira/browse/HIVE-3822
Sorry for the inconvenience.
Mark
On Fri, Jan 4, 2013 at 8:25 AM, Brad Cavanagh wrote:
> Try multiplying your values by 1000, then running the conversions. I bet
> they expect milliseconds since
Try multiplying your values by 1000, then running the conversions. I bet they
expect milliseconds since the epoch instead of seconds.
Brad.
On 2013-01-04, at 8:03 AM, John Omernik wrote:
> Greetings all. I am getting frustrated with the documentation and lack of
> intuitiveness in Hive relat
One more test:
to_utc_timestamp(from_unixtime(value), 'CST') as to_from, provided the
proper timestamp for me, however, I still had to provide the timezone which
I should NOT have to do. I know that this data coming in is in epoch time,
therefore I should be able to create a timezone without knowi
Greetings all. I am getting frustrated with the documentation and lack of
intuitiveness in Hive relating to timestamps and was hoping I could post
here and get some clarification or other ideas.
I have a field that is a string, but is actually a 10 digit int
representation of epoch time, I am goin