"use strict";
module.exports = {
up: (queryInterface, Sequelize) => {
return queryInterface.createTable("tbl_wechat_user", {
id: {
allowNull: false,
autoIncrement: true,
primaryKey: true,
type: Sequelize.INTEGER
},
name: {
type: Sequelize.STRING,
comment: ""
},
create_time: {
allowNull: false,
type: Sequelize.INTEGER(10)
},
update_time: {
allowNull: false,
type: Sequelize.INTEGER(10)
}
}).then();
},
down: (queryInterface, Sequelize) => {
return queryInterface.dropTable("tbl_wechat_user");
}
};
the above is a migrated file, but when sequelize db:migrate is executed, the datasheet is added successfully, but the field does not have comment.
excuse me, how can I add comment to the table field? Or is there no such function?