summaryrefslogtreecommitdiffstats
path: root/videos.sql
blob: b505fdf8b5c8f3782e151e3d27381a3a95da6b30 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
-- Table: public.videos

CREATE TABLE public.videos
(
    id text COLLATE pg_catalog."default" NOT NULL,
    info text COLLATE pg_catalog."default",
    html text COLLATE pg_catalog."default",
    updated timestamp with time zone,
    title text COLLATE pg_catalog."default",
    views bigint,
    likes integer,
    dislikes integer,
    wilson_score double precision,
    CONSTRAINT videos_pkey PRIMARY KEY (id)
)
WITH (
    OIDS = FALSE
)
TABLESPACE pg_default;

GRANT ALL ON TABLE public.videos TO kemal;

-- Index: id_idx

CREATE UNIQUE INDEX id_idx
    ON public.videos USING btree
    (id COLLATE pg_catalog."default")
    TABLESPACE pg_default;