mirror of
https://github.com/TeamPiped/Piped-Backend.git
synced 2024-08-14 23:51:41 +00:00
Add unauthenticated_subscriptions table.
This commit is contained in:
parent
c8f7e52820
commit
657e63332e
3 changed files with 19 additions and 0 deletions
|
@ -41,3 +41,7 @@ CREATE INDEX IF NOT EXISTS playlists_owner_idx ON playlists (owner ASC) STORING
|
|||
|
||||
--rollback DROP INDEX IF EXISTS playlists_playlist_id_idx;
|
||||
--rollback DROP INDEX IF EXISTS playlists_owner_idx;
|
||||
|
||||
CREATE INDEX IF NOT EXISTS unauthenticated_subscriptions_id_idx ON unauthenticated_subscriptions (id ASC) USING HASH STORING (subscribed_at);
|
||||
|
||||
--rollback DROP INDEX IF EXISTS unauthenticated_subscriptions_id_idx;
|
||||
|
|
|
@ -42,3 +42,7 @@ CREATE INDEX IF NOT EXISTS playlists_owner_idx ON playlists (owner ASC);
|
|||
|
||||
--rollback DROP INDEX IF EXISTS playlists_playlist_id_idx;
|
||||
--rollback DROP INDEX IF EXISTS playlists_owner_idx;
|
||||
|
||||
CREATE INDEX IF NOT EXISTS unauthenticated_subscriptions_id_idx ON unauthenticated_subscriptions (id ASC);
|
||||
|
||||
--rollback DROP INDEX IF EXISTS unauthenticated_subscriptions_id_idx;
|
||||
|
|
|
@ -74,3 +74,14 @@ CREATE TABLE IF NOT EXISTS playlists_videos_ids (
|
|||
CREATE INDEX IF NOT EXISTS playlists_videos_ids_playlist_id_idx ON playlists_videos_ids (playlist_id ASC);
|
||||
|
||||
--rollback DROP TABLE IF EXISTS playlists_videos_ids;
|
||||
|
||||
CREATE TABLE IF NOT EXISTS unauthenticated_subscriptions (
|
||||
id VARCHAR(24) NOT NULL,
|
||||
subscribed_at INT8 NOT NULL,
|
||||
CONSTRAINT unauthenticated_subscriptions_pkey PRIMARY KEY (id),
|
||||
CONSTRAINT fk_unauthenticated_subscriptions_id_channels FOREIGN KEY (id) REFERENCES channels(uploader_id)
|
||||
);
|
||||
|
||||
CREATE INDEX IF NOT EXISTS unauthenticated_subscriptions_subscribed_at_idx ON unauthenticated_subscriptions (subscribed_at ASC);
|
||||
|
||||
--rollback DROP TABLE IF EXISTS unauthenticated_subscriptions;
|
||||
|
|
Loading…
Reference in a new issue