I am trying to format a JSON which has a date key in the format:
date
date: \"2017-05-23T06:25:50\"
My current attempt i
This will work for you.
String oldstring= "2017-05-23T06:25:50.0"; Date datee = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss").parse(oldstring);