Re: [Sqlalchemy-tickets] [sqlalchemy] #2790: sqlite join rewriting fails on columns that assign alt
Brought to you by:
zzzeek
|
From: sqlalchemy <mi...@zz...> - 2013-07-27 19:52:32
|
#2790: sqlite join rewriting fails on columns that assign alternate .key
------------------------------+-------------------------------
Reporter: rgg | Owner: zzzeek
Type: defect | Status: new
Priority: highest | Milestone: 0.9.0
Component: orm | Severity: major - 1-3 hours
Resolution: | Keywords:
Progress State: in progress |
------------------------------+-------------------------------
Comment (by zzzeek):
OK well here's the issue:
{{{
#!diff
diff --git a/lib/sqlalchemy/sql/compiler.py
b/lib/sqlalchemy/sql/compiler.py
index a5f545d..e535247 100644
--- a/lib/sqlalchemy/sql/compiler.py
+++ b/lib/sqlalchemy/sql/compiler.py
@@ -1162,7 +1162,7 @@ class SQLCompiler(engine.Compiled):
use_labels=True).alias()
for c in selectable.c:
- c._label = c._key_label = c.name
+ c._label = c._key_label = c.key
translate_dict = dict(
zip(right.element.c, selectable.c)
)
}}}
want to figure out that eager version though
--
Ticket URL: <http://www.sqlalchemy.org/trac/ticket/2790#comment:2>
sqlalchemy <http://www.sqlalchemy.org/>
The Database Toolkit for Python
|