I need to convert date which is stored in varchar format into any other format, so that i can apply some numeric operations on it i.e subtraction.
I have tried some examples like:
select ((to_date(checkout, ‘yyyy-mm-dd’)- to_date(checkin, ‘yyyy-mm-dd’))) as Dateand from errdb.bookings limit 10
The output i get over here is something like 2 00:00:00.000
I want to remove the timestamp from my output
Any solutions would be helpful