1

How can I convert the date "Mon Jul 01 08:00:00 IST 2019" of type string to ISODate "2019-07-01T03:00:00.000Z"?

azro
  • 53,056
  • 7
  • 34
  • 70
ysk
  • 159
  • 1
  • 3
  • 12
  • For most purposes you should not want to convert a datetime string in one format to another format. Instead inside your program you should keep date and time in a proper date-time object, for example `ZonedDateTime` or `Instant`. Only when you need to give out a string, format your date and time into one. – Ole V.V. Jun 29 '19 at 10:52

0 Answers0