How to initialize the database by directly executing the SQL script using Flask-SQLAlchemy?

problem description

I want to execute the SQL script directly to initialize the database when initializing the flask application.
the database is Postgresql.

the environmental background of the problems and what methods you have tried

flask tutorials use the sqlite database and the SQLAlchemy package, so you can run SQL statements directly.
flask-sqlalchemy tutorials all talk about DML operations from the perspective of ORM, and there is no description of database DDL operations.

what result do you expect? What is the error message actually seen?

how can I just call flask-sqlalchemy, to perform DDL operations according to SQL scripts?
extra thought: why does the flask-sqlalchemy tutorial cover how to define objects on the program side?
is the function of flask-sqlalchemy to do the work of DBA on the program side again?
shouldn"t flask-sqlalchemy be convenient for the program side to get database objects and then perform CURD operations?


Why no one answered.

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e9ab2f-17f4.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e9ab2f-17f4.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?