filmov
tv
Hibernate Tip: How to model associations with non primary key columns
Показать описание
When you’re working with legacy database, you probably had the situation that you had to map a many-to-one association that used a non-primary key column on the to-one side.
You can easily map that with a @JoinColumn annotation. It allows you to reference any column that contains unique values, e.g., a natural id.
If you like this video, please give me your thumbs up and share it with your friends and co-workers.
Like my channel? Subscribe!
Join the free Member Library:
Want to connect with me?
#Hibernate #JPA #HibernateTips
Hibernate Tip: How to model associations with non primary key columns
Hibernate Tip: Map an Unidirectional One-to-Many Association Without a Junction Table
Hibernate Tip: SINGLE_TABLE strategy without discriminator column
Hibernate Tip: How to use a custom database sequence
Hibernate Tip : How to avoid MultipleBagFetchException
Hibernate Tip: How to create a database setup script based on entity mappings
Hibernate Tip: How does Hibernate’s native ID generator work?
Hibernate Tip: How to automatically set an attribute before persisting it
Hibernate Tip: Map 1 Entity Attribute to 2 Columns
Hibernate Tip: Difference between @NotNull and @Column(nullable = false)
Hibernate Tip: How to map an entity attribute to an Optional
Hibernate Tip: How To Map an Entity to a Query
Hibernate Tips: How to use Hibernate's native bootstrapping API
Hibernate Tip: The best way to work with scalar projections
Hibernate Tip: How to integrate an external query builder
Hibernate Tip: How to access Hibernate APIs from JPA
Hibernate Tip: How to escape table and column names
Hibernate Tip: How to persist a List of Strings as an ElementCollection
Hibernate Tip: How to map a bidirectional many-to-many association
Hibernate Tip: Customize the association mappings using a composite key
Hibernate Tip: How to map a Boolean to Y/N
Hibernate Tip: Many-to-Many Association with additional Attributes
Hibernate Tips ‘n’ Tricks - 15 Tips to solve common problems by Thorben Janssen
Hibernate Tip: Easiest way to manage bi-directional associations
Комментарии