I had asked this question on Stack Overflow. The details are at this link:

http://stackoverflow.com/questions/24836816/updating-a-few-children-in-one-to-many-relationship-deletes-all-rows-and-adds-ne

The summary is I have a parent class A and a bidirectional one-to-many 
relationship with class B. When I update the class B list for an instance 
of A, the update may involve deleting some class B instances, updating some 
of them, and adding new ones. However, I find that SqlAlchemy deletes all 
ROWS of classB, and the inserts the necessary new rows. I would have 
expected SqlAchemy to insert only new rows, not delete and add those rows 
that are being updated. Do you know what is wrong with my code?

Thanks.

-- 
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sqlalchemy+unsubscr...@googlegroups.com.
To post to this group, send email to sqlalchemy@googlegroups.com.
Visit this group at http://groups.google.com/group/sqlalchemy.
For more options, visit https://groups.google.com/d/optout.

Reply via email to