If the identifier is auto-generated, then the identifier is being set into your object during the `flush()` calls (if it is a new object)
Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On 30 April 2014 15:57, Nima Sadjadi <[email protected]> wrote: > So is it something correct? > $em->persist($object); > $em->flush(); > $id = $object->getId(); > Now should I expect that $id has a value at this stage? > > -- > You received this message because you are subscribed to the Google Groups > "doctrine-user" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > Visit this group at http://groups.google.com/group/doctrine-user. > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "doctrine-user" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/doctrine-user. For more options, visit https://groups.google.com/d/optout.
