Doctrine OneToMany relationship error
问题 I am trying to set up some ManyToOne/OneToMany relationships on objects in my database using Doctrine (2.2.3+) via Symfony2 (2.3.0) and am getting a strange error. Here are the relevant parts of the objects (many attributes to one product): /** * Product * * @ORM\Table(name="product") * @ORM\Entity */ class Product { /** * @var integer * * @ORM\Column(name="id", type="integer") * @ORM\Id * @ORM\GeneratedValue(strategy="AUTO") */ protected $id; ... /** * * @OneToMany(targetEntity=