わかりました、私は別の方法で書きます:
使用はこのマッピングを使用できます:
映画:
Movie:
type: entity
table: movie
id:
id:
type: integer
generator: { strategy: AUTO }
fields:
title: ~
createdAt:
type: datetime
oneToMany:
roles:
targetEntity: Role
mappedBy: movie
アーティスト:
Artist:
type: entity
table: artist
id:
id:
type: integer
generator: { strategy: AUTO }
fields:
fname: ~
lname: ~
birthDate:
type: datetime
#other fields for this entity
役割:
Role:
type: entity
table: role
id:
id:
type: integer
generator: { strategy: AUTO }
fields:
name: ~
manyToMany:
artist:
targetEntity: Artist
manyToOne:
movie:
targetEntity: Movie
inversedBy: roles