I've a timestamp value in the format 2005-01-31T00:00:00.000-05:00
. I want covert it to a number in the format20050131
, to equate it to a column which has the datatype of number.
I tried to do it by to_number(to_date(timestamp, 'yyyymmdd'))
. But it is resulting in error not a valid month
.
Could you please help me in resolving it.