From 05732aa0b6a95d6d6c5986b28077d7fe28edab0c Mon Sep 17 00:00:00 2001
From: Andrew Dolgov <fox@bah.spb.su>
Date: Sat, 19 Nov 2005 09:18:34 +0100
Subject: misc new schema support related work

---
 schema/ttrss_schema_pgsql.sql | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

(limited to 'schema/ttrss_schema_pgsql.sql')

diff --git a/schema/ttrss_schema_pgsql.sql b/schema/ttrss_schema_pgsql.sql
index d3e691b3c..e1d07c425 100644
--- a/schema/ttrss_schema_pgsql.sql
+++ b/schema/ttrss_schema_pgsql.sql
@@ -53,6 +53,7 @@ create table ttrss_entries (id serial not null primary key,
 	index (guid), index(title));
 
 create table ttrss_user_entries (
+	int_id serial not null primary key,
 	ref_id integer not null references ttrss_entries(id) ON DELETE CASCADE,
 	feed_id int references ttrss_feeds(id) ON DELETE CASCADE not null, 
 	owner_uid integer not null references ttrss_users(id) ON DELETE CASCADE,
@@ -100,7 +101,7 @@ insert into ttrss_labels (owner_uid,sql_exp,description) values (1,
 create table ttrss_tags (id serial not null primary key, 
 	tag_name varchar(250) not null,
 	owner_uid integer not null references ttrss_users(id) on delete cascade,
-	post_id integer references ttrss_entries(id) ON DELETE CASCADE not null);
+	post_int_id integer references ttrss_user_entries(int_id) ON DELETE CASCADE not null);
 
 create index ttrss_tags_owner_uid_index on ttrss_tags(owner_uid);
 
-- 
cgit v1.2.3-54-g00ecf

