Re: [sqlalchemy] autogenerate migrations with alembic for inherited tables

2017-04-24 Thread mike bayer
On 04/24/2017 07:21 AM, Антонио Антуан wrote: Here is definition. PostgreSQL ensures that all columns that are in "table_master" will be in the inherited tables, but the indexes won't: I should create them manually by describing it in procedure code. So, if I add new index, I should add

Re: [sqlalchemy] autogenerate migrations with alembic for inherited tables

2017-04-24 Thread Антонио Антуан
пятница, 21 апреля 2017 г., 17:07:34 UTC+3 пользователь Mike Bayer написал: > > > > On 04/21/2017 09:16 AM, Антонио Антуан wrote: > > Helllo. > > I have a model, with specified __tablename__ = 'base_table'. > > In postgresql, the table has trigger, which executes before each insert: > > it

Re: [sqlalchemy] autogenerate migrations with alembic for inherited tables

2017-04-21 Thread mike bayer
On 04/21/2017 09:16 AM, Антонио Антуан wrote: Helllo. I have a model, with specified __tablename__ = 'base_table'. In postgresql, the table has trigger, which executes before each insert: it creates partition for current month (if it not exist yet), specifies "INHERITS (base_table)" for new

[sqlalchemy] autogenerate migrations with alembic for inherited tables

2017-04-21 Thread Антонио Антуан
Helllo. I have a model, with specified __tablename__ = 'base_table'. In postgresql, the table has trigger, which executes before each insert: it creates partition for current month (if it not exist yet), specifies "INHERITS (base_table)" for new partition and insert data into it. Is there any