This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes JDBC and the fly likes How to get day, month, and year seperate from date Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "How to get day, month, and year seperate from date" Watch "How to get day, month, and year seperate from date" New topic
Author

How to get day, month, and year seperate from date

Kay Tracid
Ranch Hand

Joined: Mar 06, 2002
Posts: 148
Hi,
I want to get day, month and year from the Date object. How can I do this?
Thanks a lot!
prabhat kumar
Ranch Hand

Joined: Apr 11, 2001
Posts: 114
use
Calendar.get(Calendar.DAY_OF_MONTH).
and so on
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: How to get day, month, and year seperate from date
 
Similar Threads
scalar functions
Retrieve value from a DateField
Date problem
Retrive Month and Year
how to generate sql date