Java.sql.date extends java.util.date, so is it save to convert between the two by casting a java.sql.date as a java.util.date? Or is there some other way to convert them?
Java.sql.date extends java.util.date, so is it save to convert between the two by casting
Share
Yes, you can just upcast it.
The
java.sql.Dateis in fact nothing less or more than a representation of the SQL Date type, which has only year, month and day filled.