The question is probably very simple, but I can't find an answer anywhere...
Suppose I already have some tables declarad in a declarative way, as
below, how do I create the database schema from them?
I usually always did with the
meta.create_all() after defining the various Table('name', meta...)
On Tue, Aug 21, 2012 at 5:25 PM, andrea crotti
andrea.crott...@gmail.com wrote:
The question is probably very simple, but I can't find an answer anywhere...
Suppose I already have some tables declarad in a declarative way, as
below, how do I create the database schema from them?
I usually
2012/8/21 Simon King si...@simonking.org.uk:
The MetaData instance is available via the declarative base class, so
you should be able to do something like:
Base.metadata.create_all()
http://docs.sqlalchemy.org/en/rel_0_7/orm/extensions/declarative.html#accessing-the-metadata
Hope that
On Aug 21, 2012, at 12:50 PM, andrea crotti wrote:
2012/8/21 Simon King si...@simonking.org.uk:
The MetaData instance is available via the declarative base class, so
you should be able to do something like:
Base.metadata.create_all()