Dnia 2009-08-28, Pt o godzinie 18:29 -0400, Michael Bayer pisze:
Tomasz Jezierski - Tefnet wrote:
---
sqlalchemy.exc.ArgumentError: Column 'PhysObject.locationId' is not
represented in mapper's table. Use the `column_property()` function to
force this column to be mapped as a read-only
Dnia 2009-08-27, czw o godzinie 10:51 -0400, Michael Bayer pisze:
you can also set up primaryjoin using the actual table
columns (i.e. PhysObject.locationId == Location.__table__.c.id).
Thanks, that worked really well :). Now i am stuck with something else
in this subject:
Tefnet Developers wrote:
Dnia 2009-08-27, czw o godzinie 10:51 -0400, Michael Bayer pisze:
you can also set up primaryjoin using the actual table
columns (i.e. PhysObject.locationId == Location.__table__.c.id).
Thanks, that worked really well :). Now i am stuck with something else
in
Dnia 2009-08-28, Pt o godzinie 10:51 -0400, Michael Bayer pisze:
Tefnet Developers wrote:
Dnia 2009-08-27, czw o godzinie 10:51 -0400, Michael Bayer pisze:
you can also set up primaryjoin using the actual table
columns (i.e. PhysObject.locationId == Location.__table__.c.id).
Tomasz Jezierski - Tefnet wrote:
Awkward column_property is because of exception you'll get if try to set
Column without column_proprerty around it:
---
sqlalchemy.exc.ArgumentError: Column 'PhysObject.locationId' is not
represented in mapper's table. Use the `column_property()` function
Tomasz Jezierski - Tefnet wrote:
Awkward column_property is because of exception you'll get if try to set
Column without column_proprerty around it:
---
sqlalchemy.exc.ArgumentError: Column 'PhysObject.locationId' is not
represented in mapper's table. Use the `column_property()` function to
Tomasz Jezierski - Tefnet wrote:
---
sqlalchemy.exc.ArgumentError: Column 'PhysObject.locationId' is not
represented in mapper's table. Use the `column_property()` function to
force this column to be mapped as a read-only attribute.
ticket # 1523 has a patch that allows this approach to
Tefnet Developers wrote:
class Location(PhysObject):
Id = sqlalchemy.Column(sqlalchemy.types.Integer,
sqlalchemy.ForeignKey(PhysObject.Id), primary_key=True)
description = sqlalchemy.Column( sqlalchemy.types.String(128))
PhysObject.location = sqlalchemy.orm.relation(