Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SQL

sequelize postgresql schema

var City = sequelize.define('City', {
    id: {
        type: sequelize.Sequelize.INTEGER,
        primaryKey: true,
        autoIncrement: true,
        field: 'id'
    },
    name: {
        type: sequelize.Sequelize.STRING,
        field: 'name'   
    }
  }, {
    timestamps: false,
    tableName: 'cities'
    });
City.schema("public");
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #sequelize #postgresql #schema
ADD COMMENT
Topic
Name
1+5 =