On Jun 13, 2008, at 3:18 AM, Egil Möller wrote:

> You seem to have stumbled into the same bug as I have while i fixed  
> the "IN" SQL generation code for oracle to work inside the column  
> list, not just in the where-clause.
>
> I ended up hacking SQLAlchemy/trunk/lib/sqlalchemy/sql/expression.py  
> like this:
>
> 2166 class _BinaryExpression(ColumnElement):
> ...
> 2181     def _get_from_objects(self, **modifiers):
> 2182         res = self.left._get_from_objects(**modifiers)
> 2183         if self.operator is operators.in_op: return res
> 2184         return res + self.right._get_from_objects(**modifiers)
>
> That seems to do the trick :)
>

my congrats to you for digging into the expression code that  
deeply. :)   the actual fix though will be to make in_() add some  
extra behavior to an incoming select() so that it doesn't export it's  
froms.   Changing it on Binary as above puts functionality that is  
specific to in_() outside of where it should be handled.


--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to