-
-
Notifications
You must be signed in to change notification settings - Fork 4.3k
Closed
Labels
type: bugDEPRECATED: replace with the "bug" issue typeDEPRECATED: replace with the "bug" issue type
Description
What are you doing?
Trying to run a migration against Postgres
'use strict';
module.exports = {
up: (queryInterface, Sequelize) => {
return queryInterface.createTable('Events', {
id: {
allowNull: false,
autoIncrement: true,
primaryKey: true,
type: Sequelize.INTEGER.UNSIGNED
},
type: {
allowNull: false,
type: Sequelize.TINYINT.UNSIGNED
}
});
},
down: (queryInterface, Sequelize) => {
return queryInterface.dropTable('Events');
}
};What do you expect to happen?
Migration to successfully run An error about TINYINT not being supported.
What is actually happening?
== 20180417181241-create-events: migrating =======
(sequelize) Warning: PostgreSQL does not support INTEGER with options. Plain `INTEGER` will be used instead., '
>> Check:', http://www.postgresql.org/docs/9.4/static/datatype.html
ERROR: syntax error at or near "UNSIGNED"
If I remove unsigned I get an error about TINYINT not being supported by Postgres (which is expected).
Versions
Postgres 10.4
Sequelize CLI [Node: 9.5.0, CLI: 4.0.0, ORM: 4.37.6]
Metadata
Metadata
Assignees
Labels
type: bugDEPRECATED: replace with the "bug" issue typeDEPRECATED: replace with the "bug" issue type