[DDC-1612] Cannot call entityManager->flush($entity) with new entity Created: 19/Jan/12  Updated: 22/Jan/12  Resolved: 21/Jan/12

Status: Resolved
Project: Doctrine 2 - ORM
Component/s: ORM
Affects Version/s: 2.2-BETA1, 2.2-BETA2, Git Master
Fix Version/s: 2.2.0-RC1, 2.2
Security Level: All

Type: Bug Priority: Major
Reporter: Sascha-Oliver Prolic Assignee: Benjamin Eberlei
Resolution: Fixed Votes: 0
Labels: None


 Description   

Following works:
$entity = $em->find('Entity', 1);
$entity->setName('newName');
$em->persist($entity);
$em->flush($entity);

Following does NOT work:
$entity = new Entity();
$entity->setName('newName');
$em->persist($entity);
$em->flush($entity);



 Comments   
Comment by Benjamin Eberlei [ 21/Jan/12 ]

Fixed

Generated at Wed Jul 30 17:24:35 UTC 2014 using JIRA 6.2.3#6260-sha1:63ef1d6dac3f4f4d7db4c1effd405ba38ccdc558.