I have the following code that successfully gets me the difference between two days (in days, hours, minutes, seconds):
SimpleDateFormat format = new SimpleD
I think you should look at joda-time library http://joda-time.sourceforge.net/
Java default implementation of dates kind of suck, using joda time you can compute the intervals you want and its compatible with java Date class.
http://joda-time.sourceforge.net/quickstart.html (look at interval and time periods)