Configuring entity relationships

First, we will model the relationship between Course and Teacher. There is a one-to-many relationship between them: one teacher may teach a number of courses. Open Course.java in the editor. Open the JPA perspective in Eclipse JEE (Window | Open Perspective | JPA menu).

Get Java EE 8 Development with Eclipse now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.