Skip to content

Instantly share code, notes, and snippets.

/20170520140100_images.js Secret
Created May 20, 2017

Embed
What would you like to do?
exports.up = function(knex, Promise) {
knex.schema.createTable('images', (table) =>{
table.increments();
table.text('image_title').notNullable();
table.text('image_description');
table.text('image_path').notNullable();
table.boolean('image_is_deleted').defaultTo(false);
table.datetime('image_created_at').notNullable();
});
};
exports.down = function(knex, Promise) {
return knex.schema.dropTable('images');
};
cbravophoto=# \dt
List of relations
Schema | Name | Type | Owner
--------+----------------------+-------+----------
public | knex_migrations | table | AmazeCPK
public | knex_migrations_lock | table | AmazeCPK
(2 rows)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.