pgsql schema: remove unnecessary named indexes
This commit is contained in:
parent
5cbc1c7469
commit
c9bcda5469
1 changed files with 0 additions and 25 deletions
|
@ -98,9 +98,6 @@ create table ttrss_feeds (id serial not null primary key,
|
||||||
favicon_last_checked timestamp default null,
|
favicon_last_checked timestamp default null,
|
||||||
auth_pass_encrypted boolean not null default false);
|
auth_pass_encrypted boolean not null default false);
|
||||||
|
|
||||||
create index ttrss_feeds_owner_uid_index on ttrss_feeds(owner_uid);
|
|
||||||
create index ttrss_feeds_cat_id_idx on ttrss_feeds(cat_id);
|
|
||||||
|
|
||||||
insert into ttrss_feeds (owner_uid, title, feed_url) values
|
insert into ttrss_feeds (owner_uid, title, feed_url) values
|
||||||
(1, 'Tiny Tiny RSS: New Releases', 'http://tt-rss.org/releases.rss');
|
(1, 'Tiny Tiny RSS: New Releases', 'http://tt-rss.org/releases.rss');
|
||||||
|
|
||||||
|
@ -120,7 +117,6 @@ create table ttrss_counters_cache (
|
||||||
value integer not null default 0);
|
value integer not null default 0);
|
||||||
|
|
||||||
create index ttrss_counters_cache_feed_id_idx on ttrss_counters_cache(feed_id);
|
create index ttrss_counters_cache_feed_id_idx on ttrss_counters_cache(feed_id);
|
||||||
create index ttrss_counters_cache_owner_uid_idx on ttrss_counters_cache(owner_uid);
|
|
||||||
create index ttrss_counters_cache_value_idx on ttrss_counters_cache(value);
|
create index ttrss_counters_cache_value_idx on ttrss_counters_cache(value);
|
||||||
|
|
||||||
create table ttrss_cat_counters_cache (
|
create table ttrss_cat_counters_cache (
|
||||||
|
@ -129,8 +125,6 @@ create table ttrss_cat_counters_cache (
|
||||||
updated timestamp not null,
|
updated timestamp not null,
|
||||||
value integer not null default 0);
|
value integer not null default 0);
|
||||||
|
|
||||||
create index ttrss_cat_counters_cache_owner_uid_idx on ttrss_cat_counters_cache(owner_uid);
|
|
||||||
|
|
||||||
create table ttrss_entries (id serial not null primary key,
|
create table ttrss_entries (id serial not null primary key,
|
||||||
title text not null,
|
title text not null,
|
||||||
guid text not null unique,
|
guid text not null unique,
|
||||||
|
@ -148,7 +142,6 @@ create table ttrss_entries (id serial not null primary key,
|
||||||
lang varchar(2),
|
lang varchar(2),
|
||||||
author varchar(250) not null default '');
|
author varchar(250) not null default '');
|
||||||
|
|
||||||
-- create index ttrss_entries_title_index on ttrss_entries(title);
|
|
||||||
create index ttrss_entries_date_entered_index on ttrss_entries(date_entered);
|
create index ttrss_entries_date_entered_index on ttrss_entries(date_entered);
|
||||||
create index ttrss_entries_updated_idx on ttrss_entries(updated);
|
create index ttrss_entries_updated_idx on ttrss_entries(updated);
|
||||||
|
|
||||||
|
@ -170,10 +163,6 @@ create table ttrss_user_entries (
|
||||||
note text,
|
note text,
|
||||||
unread boolean not null default true);
|
unread boolean not null default true);
|
||||||
|
|
||||||
-- create index ttrss_user_entries_feed_id_index on ttrss_user_entries(feed_id);
|
|
||||||
create index ttrss_user_entries_owner_uid_index on ttrss_user_entries(owner_uid);
|
|
||||||
create index ttrss_user_entries_ref_id_index on ttrss_user_entries(ref_id);
|
|
||||||
create index ttrss_user_entries_feed_id on ttrss_user_entries(feed_id);
|
|
||||||
create index ttrss_user_entries_unread_idx on ttrss_user_entries(unread);
|
create index ttrss_user_entries_unread_idx on ttrss_user_entries(unread);
|
||||||
|
|
||||||
create table ttrss_entry_comments (id serial not null primary key,
|
create table ttrss_entry_comments (id serial not null primary key,
|
||||||
|
@ -182,9 +171,6 @@ create table ttrss_entry_comments (id serial not null primary key,
|
||||||
private boolean not null default false,
|
private boolean not null default false,
|
||||||
date_entered timestamp not null);
|
date_entered timestamp not null);
|
||||||
|
|
||||||
create index ttrss_entry_comments_ref_id_index on ttrss_entry_comments(ref_id);
|
|
||||||
-- create index ttrss_entry_comments_owner_uid_index on ttrss_entry_comments(owner_uid);
|
|
||||||
|
|
||||||
create table ttrss_filter_types (id integer not null primary key,
|
create table ttrss_filter_types (id integer not null primary key,
|
||||||
name varchar(120) unique not null,
|
name varchar(120) unique not null,
|
||||||
description varchar(250) not null unique);
|
description varchar(250) not null unique);
|
||||||
|
@ -255,9 +241,6 @@ create table ttrss_tags (id serial not null primary key,
|
||||||
owner_uid integer not null references ttrss_users(id) on delete cascade,
|
owner_uid integer not null references ttrss_users(id) on delete cascade,
|
||||||
post_int_id integer references ttrss_user_entries(int_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);
|
|
||||||
create index ttrss_tags_post_int_id_idx on ttrss_tags(post_int_id);
|
|
||||||
|
|
||||||
create table ttrss_version (schema_version int not null);
|
create table ttrss_version (schema_version int not null);
|
||||||
|
|
||||||
insert into ttrss_version values (127);
|
insert into ttrss_version values (127);
|
||||||
|
@ -271,8 +254,6 @@ create table ttrss_enclosures (id serial not null primary key,
|
||||||
height integer not null default 0,
|
height integer not null default 0,
|
||||||
post_id integer references ttrss_entries(id) ON DELETE cascade NOT NULL);
|
post_id integer references ttrss_entries(id) ON DELETE cascade NOT NULL);
|
||||||
|
|
||||||
create index ttrss_enclosures_post_id_idx on ttrss_enclosures(post_id);
|
|
||||||
|
|
||||||
create table ttrss_settings_profiles(id serial not null primary key,
|
create table ttrss_settings_profiles(id serial not null primary key,
|
||||||
title varchar(250) not null,
|
title varchar(250) not null,
|
||||||
owner_uid integer not null references ttrss_users(id) on delete cascade);
|
owner_uid integer not null references ttrss_users(id) on delete cascade);
|
||||||
|
@ -367,16 +348,10 @@ create table ttrss_user_prefs (
|
||||||
profile integer references ttrss_settings_profiles(id) ON DELETE CASCADE,
|
profile integer references ttrss_settings_profiles(id) ON DELETE CASCADE,
|
||||||
value text not null);
|
value text not null);
|
||||||
|
|
||||||
create index ttrss_user_prefs_owner_uid_index on ttrss_user_prefs(owner_uid);
|
|
||||||
create index ttrss_user_prefs_pref_name_idx on ttrss_user_prefs(pref_name);
|
|
||||||
-- create index ttrss_user_prefs_value_index on ttrss_user_prefs(value);
|
|
||||||
|
|
||||||
create table ttrss_sessions (id varchar(250) not null primary key,
|
create table ttrss_sessions (id varchar(250) not null primary key,
|
||||||
data text,
|
data text,
|
||||||
expire integer not null);
|
expire integer not null);
|
||||||
|
|
||||||
create index ttrss_sessions_expire_index on ttrss_sessions(expire);
|
|
||||||
|
|
||||||
create function SUBSTRING_FOR_DATE(timestamp, int, int) RETURNS text AS 'SELECT SUBSTRING(CAST($1 AS text), $2, $3)' LANGUAGE 'sql';
|
create function SUBSTRING_FOR_DATE(timestamp, int, int) RETURNS text AS 'SELECT SUBSTRING(CAST($1 AS text), $2, $3)' LANGUAGE 'sql';
|
||||||
|
|
||||||
create table ttrss_feedbrowser_cache (
|
create table ttrss_feedbrowser_cache (
|
||||||
|
|
Loading…
Reference in a new issue