[sqlalchemy] Re: ordering list: list order not updated on delete (orm)

2009-07-04 Thread Michael Bayer
On Jul 4, 2009, at 2:21 AM, wobsta wrote: > > Hi, > > in my following example I don't know how to properly delete items in > an ordered list. I can't call items.remove (as I would violate the > "items must be in a list rule"). remove the item using remove(). What's the "items must be in a list

[sqlalchemy] Re: Overload session to add a filter to every query

2009-07-04 Thread Michael Bayer
since this is the second time in three days and third time in two months this question has been asked, I've located my original answer from may and posted it on the wiki at http://www.sqlalchemy.org/trac/wiki/UsageRecipes/PreFilteredQuery . On Jul 3, 2009, at 9:39 PM, cd34 wrote: > > I

[sqlalchemy] ordering list: list order not updated on delete (orm)

2009-07-04 Thread wobsta
Hi, in my following example I don't know how to properly delete items in an ordered list. I can't call items.remove (as I would violate the "items must be in a list rule"). If I delete the item, the list order get's not updated. Is there a way to automate the necessary reorder call for this case?