I have a date column and I am trying to cast this into a view with a code below but the output does not match the requirement. I use denodo and oracle 18g as my database.
Column
A 1-Dec-20 12-Dec-20 11-Dec-20
Expected output
output I am getting after running the code below.
select to_localdate('dd-MM-yyyy', substring(replace("A", 'NULL', ''), 0, 10)) AS A from "xxtable" A 0020-12-01 0020-12-12 0020-12-11
I was able to solve this by using yy instead of yyyy format.
to_localdate('dd-MM-yy', substring(replace("A", 'NULL', ''), 0, 10)) AS A from "xxtable"
2.1m questions
2.1m answers
60 comments
57.0k users