Skip to content

Commit

Permalink
add indexes
Browse files Browse the repository at this point in the history
  • Loading branch information
ddboline committed Dec 3, 2023
1 parent db655d1 commit d8f4b69
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions migrations/V31__add_indexes.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
CREATE INDEX IF NOT EXISTS imdb_episodes_show_idx ON imdb_episodes (show);
CREATE INDEX IF NOT EXISTS imdb_episodes_season_idx ON imdb_episodes (season);
CREATE INDEX IF NOT EXISTS imdb_episodes_episode_idx ON imdb_episodes (episode);
CREATE INDEX IF NOT EXISTS imdb_ratings_show_idx ON imdb_ratings (show);
CREATE INDEX IF NOT EXISTS imdb_ratings_source_idx ON imdb_ratings (source);
CREATE INDEX IF NOT EXISTS movie_collection_show_idx ON movie_collection (show);
CREATE INDEX IF NOT EXISTS plex_event_metadata_key_idx ON plex_event (metadata_key);
CREATE INDEX IF NOT EXISTS plex_filename_filename_idx ON plex_filename (filename);
CREATE INDEX IF NOT EXISTS plex_filename_music_collection_idx ON plex_filename (music_collection_id);
CREATE INDEX IF NOT EXISTS plex_filename_collection_idx ON plex_filename (collection_id);
CREATE INDEX IF NOT EXISTS plex_metadata_parent_key_idx ON plex_metadata (parent_key);
CREATE INDEX IF NOT EXISTS plex_metadata_grandparent_key_idx ON plex_metadata (grandparent_key);
CREATE INDEX IF NOT EXISTS plex_metadata_show_idx ON plex_metadata (show);
CREATE INDEX IF NOT EXISTS trakt_watched_episodes_link_idx ON trakt_watched_episodes (link);
CREATE INDEX IF NOT EXISTS trakt_watched_episodes_season_idx ON trakt_watched_episodes (season);
CREATE INDEX IF NOT EXISTS trakt_watched_episodes_episode_idx ON trakt_watched_episodes (episode);
CREATE INDEX IF NOT EXISTS trakt_watchlist_show_idx ON trakt_watchlist (show);
CREATE INDEX IF NOT EXISTS trakt_watchlist_link_idx ON trakt_watchlist (link);

0 comments on commit d8f4b69

Please sign in to comment.