-
-
Notifications
You must be signed in to change notification settings - Fork 4.3k
Closed
Labels
good first issueFor issues. An issue that is a good choice for first-time contributors.For issues. An issue that is a good choice for first-time contributors.type: bugDEPRECATED: replace with the "bug" issue typeDEPRECATED: replace with the "bug" issue type
Description
What are you doing?
I have a model which is defined like
sequelize.define(‘Test’, {
test_key: {
field: ‘testKey’,
type: DataTypes.BIGINT,
allowNull: false
},
})Then I tried to generate the schema by calling
sequelize.sync({ alter: true, force: true })I was expecting the column name to be created as "test_key", but it turns out to be "testKey"
And when I tried to call sync() without "alter:true" like
sequelize.sync({ force: true })Everything works fine.
So there might be a issue for the alter functionality, please help to look into this.
What do you expect to happen?
I expected sync() with "alter:true" use the "field" option to create the column name.
What is actually happening?
But sync() with "alter:true" ignores the "field" option
Dialect: postgres
Dialect version: XXX
Database version: XXX
Sequelize version: 4.37.10
Tested with latest release: 4.37.10
Note : Your issue may be ignored OR closed by maintainers if it's not tested against latest version OR does not follow issue template.
DavidSonoda and dontry
Metadata
Metadata
Assignees
Labels
good first issueFor issues. An issue that is a good choice for first-time contributors.For issues. An issue that is a good choice for first-time contributors.type: bugDEPRECATED: replace with the "bug" issue typeDEPRECATED: replace with the "bug" issue type