I want to do a self join on combined but it wont let me. Essensially,
I want to join two different tables, and create aliases so I can
compare one column and make sure that each item in the column is
uniqe. If there are duplicates, I want my piece of code to show the
duplicates. Combining join with alias seems like the best way to do
this because when using other methods, if I change the duplicates to a
unique name, the name that used to be a duplicate still prints. Note
that the Header table has a foreign key reference to DiskFile and the
sql version used was 0.6.5. This is the portion of code where I am
getting an error:
combined = join(DiskFile, Header)
combined_alias = aliased(combined)
ERROR:
Traceback (most recent call last):
File "duplicatedl.py", line 32, in <module>
combined_1 = aliased(combined)
File "/opt/sqlalchemy/lib/python2.5/site-packages/sqlalchemy/orm/
util.py", line
304, in __init__
self.__target = self.__mapper.class_
AttributeError: 'SQLCompiler' object has no attribute 'class_'
Please help!
--
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.