BattleSim/migrations/20140502015332_allow_null_f...

12 lines
369 B
CoffeeScript
Raw Normal View History

2016-02-01 22:19:30 +00:00
exports.up = (knex, Promise) ->
knex.raw('ALTER TABLE teams ALTER COLUMN name DROP NOT NULL')
.then ->
knex.raw('ALTER TABLE teams ALTER COLUMN generation DROP NOT NULL')
exports.down = (knex, Promise) ->
knex.raw('ALTER TABLE teams ALTER COLUMN name SET NOT NULL')
.then ->
knex.raw('ALTER TABLE teams ALTER COLUMN generation SET NOT NULL')