On Mar 5, 2008, at 1:00 PM, Christoph Haas wrote:
> > But now I'm curious. Why do I get the ArgumentError if I try > > .filter(Company==my_company) > > while > > .filter(Company.id==my_company.id) > > works? I was comparing ORM objects directly instead of fields/ > properties > of a mapped object. But shouldn't that work, too? The relation()-based descriptors are the ones which are aware of comparisons to instances, i.e. Department.company==<somecompany>. Try saying "print Department.company==mycompany" to see how that works. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "sqlalchemy" group. To post to this group, send email to [email protected] 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 -~----------~----~----~----~------~----~------~--~---
