ce914f91fd
Reviewed-on: #1 Co-authored-by: Joseph Nelson <joseph.nelson4456@gmail.com> Co-committed-by: Joseph Nelson <joseph.nelson4456@gmail.com>
19 lines
407 B
JavaScript
19 lines
407 B
JavaScript
export const up = (pgm) => {
|
|
pgm.sql(`
|
|
CREATE TABLE collections (
|
|
id UUID PRIMARY KEY,
|
|
name TEXT,
|
|
image_id UUID,
|
|
created_at TIMESTAMP DEFAULT NOW(),
|
|
updated_at TIMESTAMP DEFAULT NOW(),
|
|
FOREIGN KEY (image_id) REFERENCES images(id)
|
|
);
|
|
`)
|
|
}
|
|
|
|
export const down = (pgm) => {
|
|
pgm.sql(`
|
|
DROP TABLE collections;
|
|
`)
|
|
}
|