Hibernate @OneToMany Bidirectional Relationship episode artwork

EPISODE · Jul 28, 2014 · 34 MIN

Hibernate @OneToMany Bidirectional Relationship

from How to Program with Java Podcast · host Trevor Page: Java Guru | Programmer | Teacher

Since we've already learned about the unidirectional @ManyToOne relationship, we can now move on to talking about what a bidirectional relationship is like, when using Hibernate. The term "bidirectional" literally means "functioning in two directions", which is the concept that we will apply in our relationships between two Java objects. When we have a bidirectional relationship between objects, it means that we are able to access Object A from Object B, and Object B from Object A. We can apply this logic to our real world coding example that we saw in the last post. The example we will use is the relationship between an Employer and an Employee. Previously, we only defined a unidirectional relationship, so we could only access the Employer from the Employee object and not vice-versa. Now let's take a look at how to transform our existing unidirectional relationship into a bidirectional one.

Episode metadata supplied by the publisher feed · Published Jul 28, 2014

Embed this episode

NOW PLAYING

Hibernate @OneToMany Bidirectional Relationship

0:00 34:09

No transcript for this episode yet

We transcribe on demand. Request one and we'll notify you when it's ready — usually under 10 minutes.

No similar episodes found.

No similar podcasts found.

Frequently Asked Questions

How long is this episode of How to Program with Java Podcast?

This episode is 34 minutes long.

When was this How to Program with Java Podcast episode published?

This episode was published on July 28, 2014.

Can I download this How to Program with Java Podcast episode?

Yes. Use the download control on the episode player to save the publisher-provided media file.
URL copied to clipboard!