executing this piece of code:
SimpleDateFormat sdfIn = new SimpleDateFormat("yyyy-MM-dd");
Date date = null;
try {
date = sdfIn.parse(value11);
} catch (ParseException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
SimpleDateFormat sdfOut = new SimpleDateFormat("MMM d, yyyy");
System.out.println(sdfOut.format( date ));
I an getting this output nov 23, 2005 instead of Nov 23, 2005 which would be much better.
Does anybody knows how to change it??
Thanks in advance
The exact strings that get generated depend on the locale you’re in. If you just use
then the system default locale will be used. Your default locale probably renders the month as
novrather thanNov.if you want a specific locale to be used, pass it in to the constructor, e.g.