On Feb 1, 3:17 pm, Kent <jkentbo...@gmail.com> wrote:
> > If the value is based on what's already been INSERTed for previous rows, 
> > I'd emit a SQL statement to get at the value.    If it's based on some kind 
> > of natural consideration that isn't dependent on the outcome of an INSERT 
> > statement, then you can do the looping above within the before_flush() 
> > event and assign everything at once.    Basically you need to "batch" the 
> > same way the UOW itself does.
>
> is IdentitySet an OrderedSet?  if I loop through session.new, for
> example, am I guaranteed to hit these in the same order they were
> added to the session?

Is there a way to work out the order in which session.new items were
added... I take it session.new is not ordered.
Did you mention you were in the works of an instance level event for
'before_flush()', similar to 'before_insert/before_update'?

-- 
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To post to this group, send email to sqlalchemy@googlegroups.com.
To unsubscribe from this group, send email to 
sqlalchemy+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/sqlalchemy?hl=en.

Reply via email to