Tech
Forums
Jobs
Books
Events
Interviews
Live
More
Learn
Training
Career
Members
Videos
News
Blogs
Login
Sign Up
Ask Question
2
Reply
How to convert date formt from MM/dd/yyyy to yyyy/MM/dd ?
Venkatesh K H
May 17 2017 3:25 AM
352
Reply
I am sending MM/dd/yyyy format from frontend to the mysql workbench database but its not storing the date as MM/dd/yyyy format. then how to convert this to yyyy/MM/dd in jsp.
I have tried this code but getting error please reply soon its urgent.
<%String start_date = "MAY-08-2017";
SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd");
Date d = formatter.parse(start_date);
System.out.println(d);
System.out.println(formatter.format(d));%>
Upload Source Code
Select only zip and rar file.
Post
Reset
Cancel
Answers (
2
)
Next Recommended Forum
Stop JavaScript code running when C# validation failed
How to write two action for one form in jsp?