Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I would like to extract data from Oracle server where I have to filter data>='2014' & here the Date field is in Date Format.
i.e. DD/MM/YYYY HH:MM:SS
So how do I convert into Year.
I dont want to use Preceding load because it is taking tooo long time.
Anyone can.
Regards,
Renuka S
Hi All,
Thanks for the reply. I got the answer for this.
To_number(To_Char("LAST_UPDATE_DATE",'YYYY'),'9999')
Regards,
Renuka S
hi,
use to_char(date_field,'yyyy')
Regards,
Hi,
in oracle there is year() too available.
so you can use like that in sql query
where year(datefield)>='2014';
Regards,
Try like this -
Year(date(floor(date_field), 'MM/DD/YYYY'))
Best Regards,
Neha
where to_date(to_char(YourDateField,'YYYY'),'YYYY') >'2014'
Hi All,
Thanks for the reply. I got the answer for this.
To_number(To_Char("LAST_UPDATE_DATE",'YYYY'),'9999')
Regards,
Renuka S
Why 9999 at the end?