hi, is there a way to pass a parameter to a subquery inside a select mapped to a class? the generated query looks like this:
select * from ( select distinct on (some_table.id) some_table.id, ... from some_table where some_condition ) as v join ... the outer select is mapped to a class, but when i try to query on that class, the conditions are naturally applied to the outer query. because of distinct in the subquery, i get random results. i need to put conditions on the inner query. (and yes, I do need that distinct in there. i can't put it to the outer query because that messes with order by. i can't use group by because not all columns respond to aggregates.) should I just drop the orm for this specific case? thanks, burak -- 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.