I have 2 dates in the format below where the month is a 3 letter string
1988-Jul-21
2016-Dec-18
How do I calculate the number of years between the dates in the above format?
I was able to calculate the difference between the dates in years when the month is an integer using Joda time like below
val y = Years.yearsBetween(new LocalDate("1988-12-21"), new LocalDate("2016-1-18"))
println( y.getYears)
Output: 27