Skip to content

Instantly share code, notes, and snippets.



Last active Jun 14, 2020
What would you like to do?
@Table(name = AppTables.employee)
public class Employee {
@GeneratedValue(strategy = GenerationType.AUTO)
@Column(name =
private long id;
@Column(name =
private String name;
@ManyToOne(fetch = FetchType.EAGER)
@JoinColumn(name = AppTables.employeeTable.department)
private Department department;
// Getters and setters are omitted for brevity
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment