[sqlalchemy] Re: simple many-to-many select

2007-04-05 Thread Ram Yalamanchili
was filter_by added recently? I have a assign_mapped class User from TG, and doing a session.query(User).filter_by doesn't work (no such method). On 4/4/07, Michael Bayer [EMAIL PROTECTED] wrote: My preference with assign_mapper at this point is to say: Client.query.filter_by(sites=siteobj)

[sqlalchemy] Re: simple many-to-many select

2007-04-05 Thread Glauco
Ram Yalamanchili ha scritto: was filter_by added recently? I have a assign_mapped class User from TG, and doing a session.query(User).filter_by doesn't work (no such method). yes, it's in the latest 0.3.6 version... this sometime it's hopeful :-) - orm: - the full featureset of

[sqlalchemy] Re: simple many-to-many select

2007-04-05 Thread Glauco
Glauco ha scritto: Ram Yalamanchili ha scritto: was filter_by added recently? I have a assign_mapped class User from TG, and doing a session.query(User).filter_by doesn't work (no such method). yes, it's in the latest 0.3.6 version... this sometime it's hopeful :-)

[sqlalchemy] Re: simple many-to-many select

2007-04-05 Thread Alexandre CONRAD
Michael Bayer wrote: My preference with assign_mapper at this point is to say: Client.query.filter_by(sites=siteobj) For the mailing list's archives correctness: Client.query().filter_by(sites=siteobj) i.e. i dont think constantly adding methods to assignmapper is going to scale,

[sqlalchemy] Re: simple many-to-many select

2007-04-04 Thread Alexandre CONRAD
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

[sqlalchemy] Re: simple many-to-many select

2007-04-04 Thread Glauco
Alexandre CONRAD ha scritto: Okay, thanks. Any idea if .filter_by() and other new generative method will be available in an assign_mapper object? Yes..it's available, the final object has identical property as a mapper Glauco --

[sqlalchemy] Re: simple many-to-many select

2007-04-04 Thread Alexandre CONRAD
Glauco wrote: Alexandre CONRAD ha scritto: Okay, thanks. Any idea if .filter_by() and other new generative method will be available in an assign_mapper object? Yes..it's available, the final object has identical property as a mapper Well, model.Client.filter_by(sites=siteobj) doesn't

[sqlalchemy] Re: simple many-to-many select

2007-04-04 Thread Michael Bayer
My preference with assign_mapper at this point is to say: Client.query.filter_by(sites=siteobj) i.e. i dont think constantly adding methods to assignmapper is going to scale, as the chances of conflicts with existing user classes grows. im into hierarchies of names rather than huge

[sqlalchemy] Re: simple many-to-many select

2007-04-03 Thread Michael Bayer
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