Okay, thanks. Any idea if .filter_by() and other new "generative" method will be available in an assign_mapper object?
http://www.sqlalchemy.org/docs/plugins.html#plugins_assignmapper I'm figuring out that join_via and join_to will no longer be used as it's not documented anymore and will be replaced .join() / .outerjoin(). Regards, -- Alexandre CONRAD Michael Bayer wrote: > > > On Apr 3, 12:39 pm, Alexandre CONRAD <[EMAIL PROTECTED]> wrote: > >>And I'd like to find all "attachments" from one client. But as there's a >>weak (secondary) table in between, I can no longer have something like: >> >> model.Attachment.id_client==c.client.id >> >>How can I achieve this ? > > > using a criterion like > and_(Attachment.c.attachment_id==attachment_has_clients.c.id_attachment, > attachment_has_clients.c.id_client=Client.c.cllient_id) > > or you could use the built in stuff: > > session.query(Attachment).filter_by(clients=someclient).list() > > >>ps: I'm using assign_mapper. >> >>Regards, >>-- >>Alexandre CONRAD > > > > > > > > --------------------------------------------------------------------------------------------------- > Texte inséré par Platinum 2007: > > S'il s'agit d'un mail indésirable (SPAM), cliquez sur le lien suivant pour > le reclasser : http://127.0.0.1:6083/Panda?ID=pav_33248&SPAM=true > --------------------------------------------------------------------------------------------------- > > --~--~---------~--~----~------------~-------~--~----~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sqlalchemy?hl=en -~----------~----~----~----~------~----~------~--~---