Hi all,

I wonder if SA can handle this use case:

An Account can contain Entries ordered by 'position' attribute.

mapper(Account, table_accounts, properties = dict(
    entries = relation(Entry, lazy=True, collection_class=ordering_list
('position'),
        order_by=[table_entries.c.position],
        passive_deletes='all', cascade='save-update',
        backref=backref('account', lazy=False),
    ),
))

I'd like to move an entry from accountA to accountB and let SA remove
the link between the entry and accountA:

    entry = accountA.entries[0]
    insort_right(accountB.entries, entry)
    assert not entry in accountA.entries    # false, entry is still in
accountA !!!!

It is possible?

Thank you,
jean-philippe
--~--~---------~--~----~------------~-------~--~----~
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