Receive data with location open and close hour as below. Unable to
location,DOW,openhour,closehour
abc,mon,0900,1630
abc,tue,0900,1630
abc,wed,0900,1700
abc,thu,0900,1700
abc,fri,0900,1700
abc,sat,0930,1300
abc,sun,0000,1000
Only option to store openhour and closehour as string. Making arithmetic operation on these columns complex.
Hive do not have time datatype. Is there an option to create a custom datatype to handle this
select cast('0130' as time) from test_table;
Error: Error while compiling statement: FAILED: ParseException line 1:22 cannot recognize input near 'time' ')' 'from' in primitive type specification (state=42000,code=40000)