- changed title to aliased() not working with subquery in join
aliased() not working with subquery in join
Issue #3281
closed
bla = literal_column('1', Integer)
temp = s.query(bla.label('bla')).subquery()
acc = aliased(Account, 'acc')
s.query(acc, temp).join(temp, temp.c.bla == acc.id).all()
raises AttributeError: 'str' object has no attribute 'corresponding_column'
Comments (2)
-
reporter -
repo owner - changed status to closed
I think you mean to say:
acc = aliased(Account, name='acc')
the second argument is currently called "alias" and is an optional SQL selectable object.
- Log in to comment