[sqlalchemy] Alembic 0.3.6 released

2012-08-15 Thread Michael Bayer
Hey lists - Alembic 0.3.6 is released. Alembic is the database migrations tool for SQLAlchemy.Alembic includes features such as minimalist scripting syntax, autogeneration of migrations, support for "offline" migrations, and an open-ended architecture that's easily embedded in many scenari

Re: [sqlalchemy] determine if relationship is a backref

2012-08-15 Thread Jason
On Wednesday, August 15, 2012 11:41:20 AM UTC-4, Michael Bayer wrote: > > > > > in this case it seems like you aren't as much concerned about the actual > mapper configuration as you are about codepaths being invoked. So we > "instrument" functions to track when they are called. > > You'd ma

Re: [sqlalchemy] Single table inheritance - column not mapped

2012-08-15 Thread Kuba Dolecki
Cool, I think the approach you outlined briefly works, and I look forward to hopefully seeing it in the next release. For now, I will just add the columns back to the AutocreatedGroup class. Again, thank you. I really appreciate your help. I'll make sure to make my emails in the future more e

Re: [sqlalchemy] Single table inheritance - column not mapped

2012-08-15 Thread Michael Bayer
On Aug 15, 2012, at 11:41 AM, Kuba Dolecki wrote: > You responded! Woot. Thanks. Here's some additional info: > > 1. __tablename__ is generated automatically based on the class name. > Flask-SQLAlchemy does this for us. The __tablename__ for AutocreatedGroup and > TopicAutocreatedGroup model i

Re: [sqlalchemy] determine if relationship is a backref

2012-08-15 Thread Michael Bayer
On Aug 15, 2012, at 11:35 AM, Jason wrote: > Is there a way to determine if a relationship property on a model class is a > backref? not in the strict sense, because a "backref" is just configurational sugar for two separate relationship() objects that are aware of each other.But you can

Re: [sqlalchemy] Single table inheritance - column not mapped

2012-08-15 Thread Kuba Dolecki
You responded! Woot. Thanks. Here's some additional info: 1. __tablename__ is generated automatically based on the class name. Flask-SQLAlchemy does this for us. The __tablename__ for AutocreatedGroup and TopicAutocreatedGroup model is both "autocreated_group". 2. Sorry, I might have included t

[sqlalchemy] determine if relationship is a backref

2012-08-15 Thread Jason
Is there a way to determine if a relationship property on a model class is a backref? For instance I have the model: class Department(Base): department_id = Column(Int(), primary_key=True) class Employee(Base): employee_id = Column(Int(), primary_key=True) department_id = Column(Int

Re: [sqlalchemy] Single table inheritance - column not mapped

2012-08-15 Thread Michael Bayer
On Aug 15, 2012, at 10:45 AM, Kuba Dolecki wrote: > Hi, > > We've used joined table inheritance up to this point, but performance issues > are making us explore single table inheritance. I'm running into a problem > with mapper configuration. Using SQLAlchemy 0.7.8, Flask-SQLAlchemy 0.16, and

Re: [sqlalchemy] an example of concrete inheritance with polymorphic_union is needed

2012-08-15 Thread Michael Bayer
On Aug 15, 2012, at 4:00 AM, Richard Rosenberg wrote: > I think at this point, the docs are simply making it worse for me. Is there > an example out there that is declarative and concise? > > This is a really simple scenario involving a single "header" table, and > multiple (identical) "detail

[sqlalchemy] Single table inheritance - column not mapped

2012-08-15 Thread Kuba Dolecki
Hi, We've used joined table inheritance up to this point, but performance issues are making us explore single table inheritance. I'm running into a problem with mapper configuration. Using SQLAlchemy 0.7.8, Flask-SQLAlchemy 0.16, and Flask 0.8. Here is the inheritance: class Community(BaseMod

[sqlalchemy] an example of concrete inheritance with polymorphic_union is needed

2012-08-15 Thread Richard Rosenberg
I think at this point, the docs are simply making it worse for me. Is there an example out there that is declarative and concise? This is a really simple scenario involving a single "header" table, and multiple (identical) "detail" tables, as in: headertable 1. id int 2. namekey varc