diff options
Diffstat (limited to 'model/sql/migrate.sql')
-rw-r--r-- | model/sql/migrate.sql | 21 |
1 files changed, 8 insertions, 13 deletions
diff --git a/model/sql/migrate.sql b/model/sql/migrate.sql index 6ca4d0f..c548724 100644 --- a/model/sql/migrate.sql +++ b/model/sql/migrate.sql @@ -1,14 +1,9 @@ -CREATE TABLE 'recipes' ( - 'id' integer PRIMARY KEY AUTOINCREMENT, - 'title' text DEFAULT '', - 'portions' text DEFAULT '', -- FIXME has to be integer - 'url' text DEFAULT '', - 'notes' text DEFAULT '' -); - -CREATE TABLE 'recipe_steps' ( - 'id' integer PRIMARY KEY, - 'recipe_id' integer DEFAULT NULL, - 'rank' integer DEFAULT NULL, - 'text' text DEFAULT '' +CREATE TABLE recipes ( + id INTEGER PRIMARY KEY, + title TEXT NOT NULL, + portions INTEGER NOT NULL, + url TEXT NOT NULL, + notes TEXT NOT NULL, + created INTEGER NOT NULL, -- unix timestamp + last_changed INTEGER NOT NULL -- unix timestamp ); |