SqlAlchemy: export table to new database

前端 未结 2 746
甜味超标
甜味超标 2021-01-18 13:02

Only recently started using python, and I like it! However, I am stuck with SqlAlchemy.

I am trying to write a script that reads an MS SQL database, query a table (a

2条回答
  •  夕颜
    夕颜 (楼主)
    2021-01-18 13:38

    See Creating and Dropping Database Tables:

    Creating … individual tables can be done via the create() … method of Table.

    For reading the source structure, see Reflecting Database Objects:

    A Table object can be instructed to load information about itself from the corresponding database schema object already existing within the database.
    […]
    The reflection system can also reflect views.

提交回复
热议问题