Home » SQL & PL/SQL » SQL & PL/SQL » problem with DAY function..........
icon6.gif  problem with DAY function.......... [message #209701] Sun, 17 December 2006 04:04 Go to next message
imtiazmasud
Messages: 49
Registered: May 2005
Location: Bangladesh
Member

hi all,
Suppose I have a date like '31-JAN-06' . Now I want that I need to find only the numeric date here like 31 from
a date('31-JAN-06')..So how Can I get this..

I have tried with DAY('31-JAN-06') function but failed...
plz help........imtiazmasud
Re: problem with DAY function.......... [message #209709 is a reply to message #209701] Sun, 17 December 2006 05:28 Go to previous messageGo to next message
orausern
Messages: 817
Registered: December 2005
Senior Member
SQL> SELECT TO_CHAR(TO_DATE('31-JAN-06','DD-MON-YY'),'DD') FROM DUAL;

TO
--
31
Re: problem with DAY function.......... [message #210022 is a reply to message #209709] Tue, 19 December 2006 00:29 Go to previous messageGo to next message
imtiazmasud
Messages: 49
Registered: May 2005
Location: Bangladesh
Member

Hi man,
Thx a lot for ur reply ...I am trying that can it solve my problem...? thx again...imtiazmasud
Re: problem with DAY function.......... [message #210023 is a reply to message #210022] Tue, 19 December 2006 00:33 Go to previous message
Maaher
Messages: 7062
Registered: December 2001
Senior Member
Hi,
I suggest you have a look at the TO_DATE and TO_CHAR functions and the DATE FORMAT models in the documentation.

Here's a direct link.

MHE
Previous Topic: TRIGGER
Next Topic: Pivot query
Goto Forum:
  


Current Time: Wed Dec 07 18:45:50 CST 2016

Total time taken to generate the page: 0.09092 seconds