Skip to Main Content

Java EE (Java Enterprise Edition) General Discussion

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

Convert date from "dd-mmm-yyyy" to yyyy-mm-dd" ??

843840Mar 30 2008 — edited Mar 31 2008
hello all

there is a small problem:

In a JSp i have
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("dd-MMM-yyyy");
Calendar tempEndDate = new GregorianCalendar();
tempStartDate.setTime(simpleDateFormat.parse(request.getParameter("startDate")));
the date i am getting from previous JSp is in "dd-mm-yyyy" format ; but i want to store the date in mySQL in
"yyyy-dd-mm" format.

how can i do this; please help me out.

thanks to you all to view and to reply
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 28 2008
Added on Mar 30 2008
6 comments
1,598 views