10 lines
357 B
MySQL
10 lines
357 B
MySQL
|
create table if not exists viewing (
|
||
|
id uuid default gen_random_uuid() not null primary key,
|
||
|
series_id uuid not null references series(id),
|
||
|
created timestamptz default now() not null,
|
||
|
updated timestamptz default now() not null,
|
||
|
season smallint not null check (season > 0),
|
||
|
episode smallint not null check (episode > 0),
|
||
|
"comment" text null
|
||
|
);
|