summaryrefslogtreecommitdiff
path: root/schema/ttrss_schema_mysql.sql
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2005-11-29 19:30:08 +0100
committerAndrew Dolgov <[email protected]>2005-11-29 19:30:08 +0100
commit53d6935b34e08cad9a72eb929becab0dbd438886 (patch)
treeb4d803a512bffdb0de0aeaca824446f77b397f00 /schema/ttrss_schema_mysql.sql
parentf8e80be444307e680594d90487dd176b4057efbf (diff)
schema: add filter actions, fix typo in PG schema
Diffstat (limited to 'schema/ttrss_schema_mysql.sql')
-rw-r--r--schema/ttrss_schema_mysql.sql16
1 files changed, 15 insertions, 1 deletions
diff --git a/schema/ttrss_schema_mysql.sql b/schema/ttrss_schema_mysql.sql
index 932e6f3a2..7c08de596 100644
--- a/schema/ttrss_schema_mysql.sql
+++ b/schema/ttrss_schema_mysql.sql
@@ -2,6 +2,7 @@ drop table if exists ttrss_version;
drop table if exists ttrss_labels;
drop table if exists ttrss_filters;
drop table if exists ttrss_filter_types;
+drop table if exists ttrss_filter_actions;
drop table if exists ttrss_user_prefs;
drop table if exists ttrss_prefs;
drop table if exists ttrss_prefs_types;
@@ -108,18 +109,31 @@ insert into ttrss_filter_types (id,name,description) values (3, 'both',
insert into ttrss_filter_types (id,name,description) values (4, 'link',
'Link');
+create table ttrss_filter_actions (id integer not null primary key,
+ name varchar(120) unique not null,
+ description varchar(250) not null unique) TYPE=InnoDB;
+
+insert into ttrss_filter_actions (id,name,description) values (1, 'filter',
+ 'Filter article');
+
+insert into ttrss_filter_actions (id,name,description) values (2, 'catchup',
+ 'Mark as read');
+
create table ttrss_filters (id integer not null primary key auto_increment,
owner_uid integer not null,
feed_id integer default null,
filter_type integer not null,
reg_exp varchar(250) not null,
description varchar(250) not null default '',
+ action_id integer not null default 1,
index (filter_type),
foreign key (filter_type) references ttrss_filter_types(id) ON DELETE CASCADE,
index (owner_uid),
foreign key (owner_uid) references ttrss_users(id) ON DELETE CASCADE,
index (feed_id),
- foreign key (feed_id) references ttrss_feeds(id) ON DELETE CASCADE) TYPE=InnoDB;
+ foreign key (feed_id) references ttrss_feeds(id) ON DELETE CASCADE,
+ index (action_id),
+ foreign key (action_id) references ttrss_filter_actions(id) ON DELETE CASCADE) TYPE=InnoDB;
create table ttrss_labels (id integer not null primary key auto_increment,
owner_uid integer not null,