I have Strings representing dates with the format 2014-11-01T18:57:24.497Z
which I want to parse
as SimpleDateFormat
.
I am using the following code
// 2014-11-01T18:57:24.497Z
SimpleDateFormat startAnalyzing = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSz");
Date start = startAnalyzing.parse(startDateAnalyzing);
When doing this I am getting an exception:
java.text.ParseException: Unparseable date: "2014-11-01T18:57:24.497Z"
at java.text.DateFormat.parse(DateFormat.java:357)
...
What I am doing wrong?