add author column to ttrss_entries, add upgrade script for 1.1.4, bump schema version
This commit is contained in:
parent
63147705ab
commit
4bc760da51
6 changed files with 25 additions and 2 deletions
|
@ -83,7 +83,8 @@ create table ttrss_entries (id integer not null primary key auto_increment,
|
|||
no_orig_date bool not null default 0,
|
||||
date_entered datetime not null,
|
||||
num_comments integer not null default 0,
|
||||
comments varchar(250) not null default '') TYPE=InnoDB;
|
||||
comments varchar(250) not null default '',
|
||||
author varchar(250) not null default '') TYPE=InnoDB;
|
||||
|
||||
create table ttrss_user_entries (
|
||||
int_id integer not null primary key auto_increment,
|
||||
|
|
|
@ -75,7 +75,8 @@ create table ttrss_entries (id serial not null primary key,
|
|||
no_orig_date boolean not null default false,
|
||||
date_entered timestamp not null default NOW(),
|
||||
num_comments integer not null default 0,
|
||||
comments varchar(250) not null default '');
|
||||
comments varchar(250) not null default '',
|
||||
author varchar(250) not null default '');
|
||||
|
||||
create index ttrss_entries_guid_index on ttrss_entries(guid);
|
||||
create index ttrss_entries_title_index on ttrss_entries(title);
|
||||
|
|
9
schema/upgrade-1.1.3-1.1.4-mysql.sql
Normal file
9
schema/upgrade-1.1.3-1.1.4-mysql.sql
Normal file
|
@ -0,0 +1,9 @@
|
|||
alter table ttrss_entries add column author varchar(250);
|
||||
|
||||
update ttrss_entries set author = ;;;
|
||||
|
||||
alter table ttrss_entries change author author varchar(250) not null;
|
||||
alter table ttrss_entries alter column author set default '';
|
||||
|
||||
update ttrss_version set schema_version = 6;
|
||||
|
12
schema/upgrade-1.1.3-1.1.4-pgsql.sql
Normal file
12
schema/upgrade-1.1.3-1.1.4-pgsql.sql
Normal file
|
@ -0,0 +1,12 @@
|
|||
begin;
|
||||
|
||||
alter table ttrss_entries add column author varchar(250);
|
||||
|
||||
update ttrss_entries set author = '';
|
||||
|
||||
alter table ttrss_entries alter column author set not null;
|
||||
alter table ttrss_entries alter column author set default '';
|
||||
|
||||
update ttrss_version set schema_version = 6;
|
||||
|
||||
commit;
|
Loading…
Reference in a new issue