On Sat, Jan 20, 2018 at 11:47 PM, Luke <[email protected]> wrote: > Michael, et al: > > The excellent documentation uses the example of an Employee from which > Manager and Engineer inherit. > > What to do when an Manger is also an Engineer?
that would imply multiple inheritance, which SQLAlchemy's inheritance facilities don't support. Mapping multiple inheritance to database tables is not something that you'd probably ever find in production-level practice though you can find things written about how it would work. > > My thought is that I want some kind of Adjacency relationship as long as all > Managers are also Engineers. Is there a simpler way to accomplish this goal > or am I thinking about the problem incorrectly? depends on what you need. You can string things together with relationship(), sure. I would try to model the system from the database schema perspective first and then see what classes arise from that. > > Thanks in advance, > > Luke Mergner > Glendale, CA > > -- > SQLAlchemy - > The Python SQL Toolkit and Object Relational Mapper > > http://www.sqlalchemy.org/ > > To post example code, please provide an MCVE: Minimal, Complete, and > Verifiable Example. See http://stackoverflow.com/help/mcve for a full > description. > --- > 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 https://groups.google.com/group/sqlalchemy. > For more options, visit https://groups.google.com/d/optout. -- SQLAlchemy - The Python SQL Toolkit and Object Relational Mapper http://www.sqlalchemy.org/ To post example code, please provide an MCVE: Minimal, Complete, and Verifiable Example. See http://stackoverflow.com/help/mcve for a full description. --- 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 https://groups.google.com/group/sqlalchemy. For more options, visit https://groups.google.com/d/optout.
