Updating (from the inverse side) bidirectional many-to-many relationships in Doctrine 2?
Customer is the inverse side of "keywords/customers" relationship with Keyword : /** * @ORM\ManyToMany(targetEntity="Keyword", mappedBy="customers", * cascade={"persist", "remove"} * ) */ protected $keywords; When creating a new customer, one should select one or more keywords. The entity form field is: $form->add($this->factory->createNamed('entity', 'keywords', null, array( 'class' => 'Acme\HelloBundle\Entity\Keyword', 'property' => 'select_label', 'multiple' => true, 'expanded' => true, ))); In my controller code, after binding the request and check if form is valid, I need to persist both