Hi,
I think that I try to setup a non-usual relationship.
I would like to link two classes to one class, like this:
# notes:
# pseudo code
# I do not need to know the parent of a given History object
class A(DeclarativeBase):
history = Column(Integer, ForeignKey('history.h_id'))
myvar = Column(String)
class B(DeclarativeBase):
history = Column(Integer, ForeignKey('history.h_id'))
myvar = Column(String)
class History(DeclarativeBase):
__tablename__='history'
dt = Column(DateTime)
myvar = Column(String)
Thank a lot in advance,
Tamas
--
You received this message because you are subscribed to the Google Groups
"sqlalchemy" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sqlalchemy.
For more options, visit https://groups.google.com/d/optout.