We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
官方文档中似乎找不到创建数据库和数据表(create table xxx)的方法. 在初次部署的时候,数据库是空的,如何在代码中依据 think.Model::schema() 中定义的表结构自动生成创建表的sql语句并执行呢? 如果需要手写sql语句并执行,又或者需要通过另一种方式先手动在数据库中创建好表格,那么再次在 schema()中定义表结构似乎就重复了.
OS Platform:
Node.js Version:
ThinkJS Version: 3.x
The text was updated successfully, but these errors were encountered:
这个目前 think-model 中没有提供,你可以使用 think-sequelize 试试,sequelize 是提供自动创建的功能的。
Sorry, something went wrong.
No branches or pull requests
DESC
官方文档中似乎找不到创建数据库和数据表(create table xxx)的方法.
在初次部署的时候,数据库是空的,如何在代码中依据 think.Model::schema() 中定义的表结构自动生成创建表的sql语句并执行呢?
如果需要手写sql语句并执行,又或者需要通过另一种方式先手动在数据库中创建好表格,那么再次在 schema()中定义表结构似乎就重复了.
ENV
OS Platform:
Node.js Version:
ThinkJS Version:
3.x
The text was updated successfully, but these errors were encountered: