SyntaxFix
Write A Post
Hire A Developer
Questions
If you're looking for short answer:
In the case of using java.util.Date, Java doesn't really know how to directly relate to SQL types. This is when @Temporal comes into play. It's used to specify the desired SQL type.
@Temporal
Source: Baeldung