日期:2014-05-18 浏览次数:20826 次
public static void main(String[] args) throws Exception {
String date = "20131203";
DateFormat df = new SimpleDateFormat("yyyyMMdd");
Date d = df.parse(date);
df = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
String newDate = df.format(d);
System.out.println(newDate);
}