workaround against ttrss_enclosures mysql data being wrong (nukes the enclosures table)
This commit is contained in:
parent
42a5226a74
commit
f574fec6a6
5 changed files with 24 additions and 3 deletions
|
@ -2,7 +2,7 @@
|
||||||
require_once "functions.php";
|
require_once "functions.php";
|
||||||
|
|
||||||
define('EXPECTED_CONFIG_VERSION', 18);
|
define('EXPECTED_CONFIG_VERSION', 18);
|
||||||
define('SCHEMA_VERSION', 55);
|
define('SCHEMA_VERSION', 56);
|
||||||
|
|
||||||
if (!file_exists("config.php")) {
|
if (!file_exists("config.php")) {
|
||||||
print "<b>Fatal Error</b>: You forgot to copy
|
print "<b>Fatal Error</b>: You forgot to copy
|
||||||
|
|
|
@ -225,7 +225,7 @@ create table ttrss_tags (id integer primary key auto_increment,
|
||||||
|
|
||||||
create table ttrss_version (schema_version int not null) TYPE=InnoDB;
|
create table ttrss_version (schema_version int not null) TYPE=InnoDB;
|
||||||
|
|
||||||
insert into ttrss_version values (55);
|
insert into ttrss_version values (56);
|
||||||
|
|
||||||
create table ttrss_enclosures (id serial not null primary key,
|
create table ttrss_enclosures (id serial not null primary key,
|
||||||
content_url text not null,
|
content_url text not null,
|
||||||
|
|
|
@ -201,7 +201,7 @@ create index ttrss_tags_owner_uid_index on ttrss_tags(owner_uid);
|
||||||
|
|
||||||
create table ttrss_version (schema_version int not null);
|
create table ttrss_version (schema_version int not null);
|
||||||
|
|
||||||
insert into ttrss_version values (55);
|
insert into ttrss_version values (56);
|
||||||
|
|
||||||
create table ttrss_enclosures (id serial not null primary key,
|
create table ttrss_enclosures (id serial not null primary key,
|
||||||
content_url text not null,
|
content_url text not null,
|
||||||
|
|
16
schema/versions/mysql/56.sql
Normal file
16
schema/versions/mysql/56.sql
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
begin;
|
||||||
|
|
||||||
|
drop table ttrss_enclosures;
|
||||||
|
|
||||||
|
create table ttrss_enclosures (id serial not null primary key,
|
||||||
|
content_url text not null,
|
||||||
|
content_type varchar(250) not null,
|
||||||
|
post_id integer not null,
|
||||||
|
title text not null,
|
||||||
|
duration text not null,
|
||||||
|
index (post_id),
|
||||||
|
foreign key (post_id) references ttrss_entries(id) ON DELETE cascade) TYPE=InnoDB;
|
||||||
|
|
||||||
|
update ttrss_version set schema_version = 56;
|
||||||
|
|
||||||
|
commit;
|
5
schema/versions/pgsql/56.sql
Normal file
5
schema/versions/pgsql/56.sql
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
begin;
|
||||||
|
|
||||||
|
update ttrss_version set schema_version = 56;
|
||||||
|
|
||||||
|
commit;
|
Loading…
Reference in a new issue