I am new to HIVE and I need to get the last day of previous month from a table in hive.
SQL equivalent ---
select last_day(add_months(sysdate,-1)) from dual;
I could only get previous day in the internet which is something like
select *
from table1
where dt >= from_unixtime(unix_timestamp()-1*60*60*24, 'yyyyMMdd');
could someone please help me with the query?
Thanks Rakesh