full blown pg

This commit is contained in:
ntr committed 2022-07-26 00:42:47 +10:00
1 parent 245616acd4
commit dde9646179
13 files changed
+323 -175

No files matched your search

+23
View File
@@ -0,0 +1,23 @@
exports.up = async knex => {
await knex.schema.createTable('listings', table => {
table.integer('id')
.primary();
table.uuid('want')
table.foreign('want')
.references('id')
.inTable('wants')
.onDelete('CASCADE');
table.integer('seller')
.notNullable()
.index();
table.jsonb('data')
.notNullable();
table.timestamps(true, true);
});
};
exports.down = async () => true;