Re: basic math

2015-05-21 Thread Craig Jones
t the "a" term > print cos(a[0]*pi/180.0)*cos(b[0]*pi/180.0) * cos(b[1]*pi/180.0 - > a[1]*pi/180.0) > > Does this matter? > > On Thu, May 21, 2015 at 9:49 AM, Craig Jones wrote: > >> I have what I thought was going to be a very simple math operation in >>

basic math

2015-05-21 Thread Craig Jones
feels like there is some order of operations issue but surely that would have been seen by now. It must be something I am doing wrong. I am using Hive 0.14.0.2.2.0.0-2041 Craig -- Craig Jones, PhD Data Scientist Spry, Inc em: cjo...@spryinc.com web: http://spryinc.com

Re: casting of hour and minute addition issue

2015-02-18 Thread Craig Jones
our()/minute()/second()) > > A workaround is to do "set hive.cache.expr.evaluation=false;" before > running the query. > > > Jason > > On Feb 18, 2015, at 11:06 AM, Craig Jones wrote: > > I have a unix time that I need to convert time-zones and then do some

casting of hour and minute addition issue

2015-02-18 Thread Craig Jones
geles") ) as double)/60.0 as test1, cast(hour( from_utc_timestamp( from_unixtime(1367445469, '-MM-dd HH:mm:ss'), "America/Los_Angeles") ) as double) + 0.15 as test2 from the_table limit 100; I get the following: _c0, hour, minute, fractional_hour, hour_minute,