I am trying to extract the year, month and day part of a timestamp column in hive.
At present the output looks like 2016-05-20 01:08:48. I want it to output only the 2016-05-20 part. I have tried using SELECT from_unixtime(unix_timestamp(date,'yyyy-mm-dd')) FROM ANS.test
but it hasn't work.