Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

SYSDATE

Status
Not open for further replies.

arpan

Programmer
Oct 16, 2002
336
IN
How do I get only the DAY part or the MONTH part or the YEAR part using SYSDATE from the table DUAL? For e.g. if the SYSDATE is 26-FEB-03, then what function do I use so that DAY=26, MONTH=FEB (or 02 or simply 2) & YEAR=03 (or 2003)?

Thanks,

Arpan
 

select to_char(SYSDATE,'DD') from dual;

select to_char(SYSDATE,'YYYY') from dual;
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top