This method is the conversion method for timestamp.
These days to do the Excel import function, which has a few time slots, so use this class to convert the imported string format timestamp format.
Accidentally appeared.
Java.lang.IllegalArgumentException:Timestamp format must be YYYY-MM-DD HH:MM:SS[.FFFFFFFFF] exception.
After detection, the local does not have this exception, so continue to find the timestamp class some relevant information, and finally in a small example to obtain the results, as follows:
New SimpleDateFormat ("yyyy-MM-dd HH:mm:ss"); = Df.format (new Date ());
Thrown Java.lang.IllegalArgumentException:Timestamp format must be YYYY-MM-DD HH:MM:SS[.FFFFFFFFF]
Be sure to note the format of the time format, where the MM of the month must be capitalized, the year and day must be lowercase yyyy-mm-dd HH:mm:ss
Anomalies, thus, jdk1.6 above the requirements of the format is significantly more rigorous than 1.5.
Java.lang.IllegalArgumentException:Timestamp format must be YYYY-MM-DD HH:MM:SS[.FFFFFFFFF]