Hibernate – Mapping Date, Time and Timestamp
Learn to map Java 8 classes (LocalDate, LocalTime or LocalDateTime etc) to SQL types while storing the time-based values in the database.
Learn to map Java 8 classes (LocalDate, LocalTime or LocalDateTime etc) to SQL types while storing the time-based values in the database.
When we annotate the Java POJOs with JPA annotations and make them persistent entities, we can face situations where two entities can be related, and we must reference these entities from each other. This reference between the entities can be either uni-direction or in bi-direction. Creating these references is called …
Hibernate one to many mapping is made between two entities where the first entity can have a relation with multiple instances of the second entity but the second can be associated with only one instance of the first entity. It is a 1 to N relationship. For example, in any …
Hibernate/JPA @ManyToMany association example using join column in the database. Learn to create unidirectional and bidirectional mappings.
Learn to create and manage one-to-one relationships between entities in a hibernate/JPA based application using @OneToOne annotation.
HowToDoInJava provides tutorials and how-to guides on Java and related technologies.
It also shares the best practices, algorithms & solutions and frequently asked interview questions.