[sqlalchemy] Re: [PATCH] filter_by_via

2007-06-03 Thread Gaetan de Menten
On 6/2/07, Michael Bayer [EMAIL PROTECTED] wrote: On Jun 2, 2007, at 6:02 AM, Gaetan de Menten wrote: Hmmm, after some more thoughts there is one little aspect of that which bothers me: once you joined to something, you can't add filtering criteria on the initial table/class. This is

[sqlalchemy] Re: [PATCH] filter_by_via

2007-06-03 Thread Michael Bayer
On Jun 3, 2007, at 8:10 AM, Gaetan de Menten wrote: - ClauseElement support would be removed from filter_by(). you can just use filter() for those. the older _by() methods, which i want to deprecate, would be left alone for backwards compatibility. What do you replace order_by with? oh,

[sqlalchemy] PROPOSAL: whack query.select(), selectfirst(), selectone(), select_by(), selectfirst_by(), selectone_by(), get_by(), auto-join feature

2007-06-03 Thread Michael Bayer
This is being discussed in a different thread and it was suggested I put this up in its own brightly lit thread so that people can notice it. now that the Query object in 0.3 has merged an enhanced set of capabilities from the SelectResults extension, namely that it behaves in a

[sqlalchemy] Re: PROPOSAL: whack query.select(), selectfirst(), selectone(), select_by(), selectfirst_by(), selectone_by(), get_by(), auto-join feature

2007-06-03 Thread Eric Ongerth
Well, that answers my next N anticipated questions on this list plus essentially every unasked-yet one in my backlog. These consistency/ predictability-of-syntax/redundancy points cut to the core of every issue I've had and/or every time I've had to hit the docs for more than a brief reminder.

[sqlalchemy] Re: PROPOSAL: whack query.select(), selectfirst(), selectone(), select_by(), selectfirst_by(), selectone_by(), get_by(), auto-join feature

2007-06-03 Thread Gaetan de Menten
On 6/3/07, Michael Bayer [EMAIL PROTECTED] wrote: - the methods select(), selectfirst(), selectone(), select_by(), selectfirst_by(), selectone_by() and get_by() would be deprecated. this means they will remain present on the Query object but the documentation would be reorganized to talk

[sqlalchemy] Re: PROPOSAL: whack query.select(), selectfirst(), selectone(), select_by(), selectfirst_by(), selectone_by(), get_by(), auto-join feature

2007-06-03 Thread Mike Orr
On 6/3/07, Michael Bayer [EMAIL PROTECTED] wrote: - the methods select(), selectfirst(), selectone(), select_by(), selectfirst_by(), selectone_by() and get_by() would be deprecated. this means they will remain present on the Query object but the documentation would be reorganized to talk only

[sqlalchemy] Re: PROPOSAL: whack query.select(), selectfirst(), selectone(), select_by(), selectfirst_by(), selectone_by(), get_by(), auto-join feature

2007-06-03 Thread Michael Bayer
On Jun 3, 2007, at 5:29 PM, Mike Orr wrote: I would suggest renaming .list() to .all(). It seems funny having a method with the same name and same behavior as list(query) -- I can never decide which to use. list() has been around awhile and is also derived from hibernate's similar

[sqlalchemy] Re: PROPOSAL: whack query.select(), selectfirst(), selectone(), select_by(), selectfirst_by(), selectone_by(), get_by(), auto-join feature

2007-06-03 Thread Mike Orr
On 6/3/07, Michael Bayer [EMAIL PROTECTED] wrote: im giong to look into optimizing the cloning. as ive said, hibernate's criteria object behaves generatively but doesnt actually copy the object; several folks here seem to want the generativeness. ive been considering sneaking in a

[sqlalchemy] Re: Weakly-referenced object error

2007-06-03 Thread Mike Orr
No weak-reference error for three days now so it looks like the MySQLdb upgrade cured it. Curious because I've been running other sites sites with that same older version and never gotten that error. But this is the first site that's mulththreaded (Pylons rather than Quixote) so I bet that had

[sqlalchemy] Left join or subselect syntax(more than one filter on join key)

2007-06-03 Thread aruna-cgx
SQL query for left join which give my desire result is as follow. i can use left join or sub select, though I prefer to use left join but I am Ok with subselect also. I don't know how to write this query in sqlalchemy. I refered document, but my query differes on join key as I have more than