Thanks for the reply Marco, just wanted to check there wasn't functionality 
I was missing in postFlush!

I'll take a look into doing it this way then.

Thanks

On Tuesday, 6 May 2014 12:26:44 UTC+1, Marco Pivetta wrote:
>
> You'd probably need to build a stateful listener that:
>
>  - collects all changed/inserted/deleted entities in `onFlush`
>  - then applies operations to those entities in `postFlush`
>
> Cheers,
>
> Marco Pivetta 
>
> http://twitter.com/Ocramius      
>
> http://ocramius.github.com/
>  
>
> On 14 April 2014 12:47, James <[email protected] <javascript:>>wrote:
>
>> Hi,
>>
>> I'm trying to register a PostFlush event listener and retrieve a list of 
>> all entities that were flushed. Is this possible?
>>
>> If not, what is the recommended approach? I want to be sure the entity 
>> was inserted correctly before the event is triggered. As far as I'm aware, 
>> an OnFlush event listener would still be triggered even if a MySQL 
>> duplicate key exception was raised in the transaction (correct me if I'm 
>> wrong here).
>>
>> Thanks
>>
>> -- 
>> 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] <javascript:>.
>> To post to this group, send email to [email protected]<javascript:>
>> .
>> 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.

Reply via email to