[JPA] 다대다 연관관계 @ManyToMany

jpa, spring

N:N 연관관계 살펴보기 #

image


구현 #

create table author_books (
   author_id bigint not null,
    books_id bigint not null
)

다대다 관계는 중간 entity 를 만들어서 일대다 일대다 로 처리한다.


참고 #