diff --git a/CHANGELOG b/CHANGELOG index ae28fc0e..27d114fc 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -3,6 +3,7 @@ Version 0.8.2 (????-??-??) Bug fixes: - Enforce foreign key constraints in MySQL +- Widen most text fields for MySQL Version 0.8.1 (2019-10-28) ========================== diff --git a/sql/MySQL/5.sql b/sql/MySQL/5.sql index 6756300b..06697be4 100644 --- a/sql/MySQL/5.sql +++ b/sql/MySQL/5.sql @@ -2,8 +2,6 @@ -- Copyright 2017 J. King, Dustin Wilson et al. -- See LICENSE and AUTHORS files for details --- Please consult the SQLite 3 schemata for commented version - -- Drop unnecessary indexes drop index id on arsse_folders; drop index id on arsse_feeds; @@ -86,10 +84,12 @@ alter table arsse_sessions add primary key(id(768)); alter table arsse_tokens drop primary key; alter table arsse_tokens modify id longtext; alter table arsse_tokens add primary key(id(512), class); +drop index url on arsse_feeds; +alter table arsse_feeds modify url longtext not null; +alter table arsse_feeds add unique index(url(255), username, password); alter table arsse_feeds modify title longtext; alter table arsse_feeds modify favicon longtext; alter table arsse_feeds modify source longtext; -alter table arsse_feeds modify etag longtext; alter table arsse_feeds modify err_msg longtext; alter table arsse_articles modify url longtext; alter table arsse_articles modify title longtext; @@ -108,7 +108,6 @@ drop index owner on arsse_labels; alter table arsse_labels modify name longtext not null; alter table arsse_labels add unique index(owner, name(255)); - -- Fix foreign key constraints alter table arsse_folders add foreign key(owner) references arsse_users(id) on delete cascade on update cascade; alter table arsse_folders add foreign key(parent) references arsse_folders(id) on delete cascade; diff --git a/sql/PostgreSQL/5.sql b/sql/PostgreSQL/5.sql index ac48a432..5e96fb43 100644 --- a/sql/PostgreSQL/5.sql +++ b/sql/PostgreSQL/5.sql @@ -2,6 +2,7 @@ -- Copyright 2017 J. King, Dustin Wilson et al. -- See LICENSE and AUTHORS files for details --- Please consult the SQLite 3 schemata for commented version +-- This schema version strictly applies fixes for MySQL, +-- hence this file is functionally empty update arsse_meta set value = '6' where "key" = 'schema_version'; diff --git a/sql/SQLite3/5.sql b/sql/SQLite3/5.sql index 24c5b914..942e9a6a 100644 --- a/sql/SQLite3/5.sql +++ b/sql/SQLite3/5.sql @@ -2,6 +2,9 @@ -- Copyright 2017 J. King, Dustin Wilson et al. -- See LICENSE and AUTHORS files for details +-- This schema version strictly applies fixes for MySQL, +-- hence this file is functionally empty + -- set version marker pragma user_version = 6; update arsse_meta set value = '6' where "key" = 'schema_version';