ZonedDateTime format and parsing exception
Advertisements I have a problem with parsing zoned date time: DateTimeFormatter format = DateTimeFormatter.ofPattern("yyyy-MM-ddzhh:mm"); ZonedDateTime.parse(s, formatter); and error: java.time.format.DateTimeParseException: Text ‘2022-05-24UTC12:15’ could not be parsed at index 10 whats wrong with this code ? thanks >Solution : tl;dr – You have the wrong pattern… The character z is not able to parse "UTC" because UTC… Read More ZonedDateTime format and parsing exception