On May 12, 2008, at 1:20 PM, [EMAIL PROTECTED] wrote:
> > On Monday 12 May 2008 18:12:39 Bobby Impollonia wrote: >> I dont see how this: >> cls.query.left_bracket().filter_or(cls.y == >> 17).filter_or(cls.x==27).right_bracket() >> is clearer than this: >> cls.query.filter(or_(cls.y == 17, cls.x==27)) > it's not. it's not about replacing the or_. noone should use it that > way... > > u have horses and owners with houses and hats. > give me horses (whose owners have a hat of size 10 and color green) or > (whose owners have a house of color red) or (have no tail) filter(or_( horses.owners.any(hatsize=10, color='green'), horses.owners.any(and_(owners.house_id==houses.house_id, houses.color=='red')), horses.tail == None )) --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---