Converting the date returned from mongo to this format 2015-10-25
问题 I have a json file returned from mongo db as follow: [ { "_id": { "$date": "2014-10-19T04:00:00.000Z" }, "value": 29 }, { "_id": { "$date": "2014-10-20T04:00:00.000Z" }, "value": 20 }, { "_id": { "$date": "2014-10-21T04:00:00.000Z" }, "value": 21 } ] Now I want to read the date in java in the following format: 2014/10/25 but when I use: System.out.println("DAte is : "+result.get("_id").toString() ); the result is : DAte is : Sun Oct 19 01:00:00 ADT 2014 Then only thing that comes to my mind