I'm having an invalid date: with month > 12.
String input = "12-30-2017";
DateFormat inputFormatter = new SimpleDateFormat("yyyy-MM-dd");
Date date = inputFormatter.parse(input);
while I have my debug cursor at the date , it gives me 12-06-2019. It seems it is adding the months and making a valid date.
I need to throw invalid date here. how to do that.