Dmitriy Pleshevskiy
f98dd4f0c8
I added a single transaction option for apply, upgrade, and downgrade commands, which wraps all migrations into a single transaction. This gives you the ability to safely roll up migrations and, if some unforeseen situation occurs, roll them back. Unfortunately if there is an error in syntax, mysql will not rollback the migration and commits automatically :( I will research this issue. Closes #2
9 lines
256 B
SQL
9 lines
256 B
SQL
-- Your SQL goes here
|
|
|
|
CREATE TABLE articles (
|
|
id serial PRIMARY KEY,
|
|
title text NOT NULL CHECK (length(title) > 0),
|
|
content text NOT NULL,
|
|
created_at timestamp NOT NULL DEFAULT current_timestamp
|
|
);
|