0% found this document useful (0 votes)
141 views49 pages

Specification

The document describes a database system that imitates the Netflix streaming platform. It includes entity relationship diagrams and descriptions of the tables that store information about users, profiles, movies, series, episodes, actors, languages, devices, payments and more. The database is implemented using PostgreSQL and is designed to mimic key functionality and data of the Netflix service.

Uploaded by

Aditya Tidke
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
141 views49 pages

Specification

The document describes a database system that imitates the Netflix streaming platform. It includes entity relationship diagrams and descriptions of the tables that store information about users, profiles, movies, series, episodes, actors, languages, devices, payments and more. The database is implemented using PostgreSQL and is designed to mimic key functionality and data of the Netflix service.

Uploaded by

Aditya Tidke
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 49

Machine Translated by Google

LUBLIN UNIVERSITY OF TECHNOLOGY

Faculty of Electrical Engineering and Computer Science

The Faculty of Informatics

DATABASE SYSTEMS ENGINEERING

Database system of the "Netflix" platform

Authors:

Grzegorz Jan Cichocki


Marcin Dominik Cieÿla

Piotr Czajka

Marek Krzysztof Cichoÿ

Lublin 2021
Machine Translated by Google

1. Project description

The project involves preparing a database that imitates the functionality and capabilities of the
Netflix streaming platform. Netflix has been around for many years and is popular in many countries
western countries, including Poland. For a monthly fee, the service allows you to watch any
number of films and series available on the platform. In the service, we create a user account, but
it is divided into profiles. Each profile can have its own name and profile photo, the pool of
which is defined in the database. Each profile also has its own video viewing history and
series generated based on current viewing and the list of works you want to watch.
The profile can return to watching a given production from the point at which it previously
stopped watching. Each user can also be assigned a preferred language in which the interface
should be displayed.

The user can use the platform on many devices, the types of which are listed in the dictionary
table. Each device is saved as a device type, its IP address and login region. The user can also
connect several payment methods for subscriptions -
subscription types are listed in the appropriate table. You can pay by gift card and credit
card.

Movies and series are in separate tables, with the series connected to the "Episode" table, which
lists all episodes of the series, including their titles, covers, types and access paths. Films
constitute one whole and they are also characterized by fields such as title, type or place of
production. We can sort films based on their country of origin and the actors appearing in
them. Actors can appear in many productions, so you can even search for movies or series by
their names. Movies and series also have their own age categories.

The entity relationship diagram was prepared in the Visual Paradigm environment. Selected engine
the database is PostgreSQL, and management is possible using dedicated pgAdmin 4
software. The whole thing runs on a computer with the GNU/Linux Pop!_OS 20.10 operating
system.
Machine Translated by Google

2. Entity relationship diagram of the designed database


The ERD (Entity Relationship Diagram) has been divided into two parts to improve readability. The
cut lines of the relationship have been signed accordingly. The entity relationship diagram was prepared in
the Visual Paradigm environment.

Photo 1: Left part of the ERD diagram


Machine Translated by Google

Photo 2: Right part of the diagram

Photo 3: View of the entire ERD diagram


Machine Translated by Google

3. Description of tables

Table 1: Database table description

Table name Type Description

series dane Data of series available to watch


on the platform

episode dane Data of specific episodes of specific


series available on the
platform
actor dane Details of actors who play in given
series and films

genre validation Dictionary table containing


different genres of movies
device subset Dictionary table containing
the types of different devices
that can run the platform

country validation The names of the countries the user,


video or video may come from
serial

film dane A table containing all the films


available to watch on
platform along with various
information

device_user dane A table connecting a given


user with the device and the mark
of last use

user dane Information about the platform


user, such as username,
password or email

profile_is_watching dane Contains information about the


currently watched movie or series in
the form of an ID

watching_history dane A collection of movies and series episodes

played by a given profile


user

payment_plans subset A table listing possible subscription


plans and
their prices

payment dane Table with information about


Machine Translated by Google

payments made

user_profiles dane Information about your user


profile, including your name
and whether you are an adult

gift_card dane Details of gift cards used to


launch the subscription

credit_card dane Payment card details provided


to start and pay for the
subscription

profile_photos subset Locations for profile


photos in the form of file paths

languages validation Names of languages that can


be used in videos
series_wanted_to_watch dane List of series to watch by
series ID form users

film_wanted_to_watch dane A list of movies that the user would


like to watch in the form of a
movie ID
Machine Translated by Google

4. Description of relationships between entities

Table 2: The first part of the table describing entity relationships

actor genre
region
cou episode

a user_

g
profile_is_w
w
a
film
a
series_w

series 1:N M: X N: 1 M:N 1:NXX 1:NXXXX

N
actor N:1 X M: XXXXXXXXX
N
genre N: X M: XXXXXXXXX
M N
film X N: N: N: M:NXX 1:NX 1:1 XXX
M M 1

age_category 1:NXX 1:N XXXXXXXXX

country N: XXN: X X 1:N X X X X 1:N X


M M
episode N:1 X X X X X X X X 1:1 X X X

user X X X X X N:1 X X X X X X 1:N

film_wanted_to_ XXXN:1 XXXX XXXX 1:1


watch
series_wanted_to N:1 XXXXXXXX X X X 1:1
_watch
profile_is_ X X X 1:1 X X 1:1 X X X 1:1 X 1:1
watching
watching XXXXXXXXXX 1:1 XX
_history
region X X X X X N:1 X X X X X X X

user_ X X X X X X X N:1 1:1 1:1 1:1 X X


profiles
Machine Translated by Google

Table 3: The second part of the table describing entity relationships

region

p
profile_

gift_card p
la

credit_ device_
user_

hotos
p
p

user 1:N X X X M:N X X X X M:N X

user_ N:1 XN:1 N:1 X XXXXXX


profiles
region XX XXX X X X X 1:N X

languages X 1:NX XX XXXXXX

profile_ X 1:NXX X XXXXXX


photos
payment_method N:M X X X X N:1 N:1 X 1:NXX

gift_card X X X X X 1:N XXXXX

credit_card X X X X X 1:N X XXXX

payment_ XXXXXX XX 1: NXX


plans
payment XXXXN:1 XXN:1 XX

device N:M X N:1 X X X XXXX N:1

device_ XXXXXX X X X X 1:N


type
Machine Translated by Google

5. Description of table fields

Table 4: User Table

Field name Field type Is the field required? Is there value Description

unique?
id_user total SO SO Internal user
ID

nick character SO SO A string


(max. 50) specifying the
username

character hash_password SO NO A string


(max. 255) specifying the
encrypted
password
salt character SO NO A string
(max. 255) specifying the salt
to add to the
password
e-mail character SO SO A string of
(max. 100) characters
specifying the email address

age data SO NO Determining date


user's
age
country_id total SO NO An identifier
relating to the
country
the user
comes
from
character phone_number NO NO A string of
(max.12) characters
specifying the
user's phone number

Table 5: User_profiles Table


Field name Field type Is the field there? Is value Description

required? Is
unique?
id_user_ total SO SO ID
Machine Translated by Google

profile user
profile
nickname character SO NO A string of
(max. 45) characters
specifying the profile name
profile_photosid total SO NO An identifier
that refers to
the profile
picture of
the profile
userid total SO NO An identifier
relating to the

user in question

profile
is_adult binary SO NO A sign
indicating whether
the profile
user is an
adult
languagesid total SO NO An identifier
relating to
the
language assigned to
profile
Film_wanted_to_watchid total NO NO An identifier
relating to
the list of
movies to watch
Series_wanted_to_watchid caÿkowity NO NO An identifier
relating to
the list of
series to watch

Table 6: profile_is_watching table


Field name Field type Is the field required? Is value Description

is it unique?
Id_session total SO SO Session ID

User_ total SO NO An identifier


profilesid relating to the
user's
profile
Episode_ total NO NO An identifier
serieid relating to a
given
episode of the series
Movies total NO NO ID
Machine Translated by Google

relating to a
given film
date time sign SO NO A
date specifying the time
start watching

Table 7: Film Table

Field name Field type Is the field there? Is value Description

required? Is
unique?
id_Movie total SO SO Video ID

title character SO NO A string


(max. 100) specifying
the title of the movie
how_long total SO NO An
integer
specifying
the length of the movie in
minutes
poster character SO NO A string
(max. 100) specifying
the path to the file
with a movie
poster
production_ data SO NO Date

year specifying the year


of production of the film
path_to_file character SO SO A string
(max. 100) specifying
the path to the file
with a movie

age_categoryid total SO NO An identifier


relating to the
video's
category
about character SO NO A string
(max. 500) specifying the description
movie
add_time time sign SO NO
Determining date
the moment
of adding the film to

the platform

Table 8: Credit_card Table

Field name Field type Is the field there? Is value Description

required? Is
unique?
Id_credit_card total SO SO Internal
Machine Translated by Google

identyfikator
credit_card
Card_number Character (max. 16) SO SO A
string
specifying the card number
Cvc Character(max. 3) SO SO
Specifying string
CVC number
of a given card
Expiration_date Character(max. 5) SO SO A
string
specifying
the card's expiration date
Owner_name Characteristic SO SO A
(max. 255) string specifying the name
the person to whom
the card belongs
Owner_lastname Characteristic SO SO A
(max. 255) string
specifying the person's name
to which it belongs
can

Tabela 9: Tabela Payment_method


Field name Field type Is the field there? Is value Description

required? Is
unique?
Id_payment_method integer SO SO Internal
identifier
payment_metho
d

Credit_cardid total SO SO An
integer that
assigns a given
credit
card to the

payment method
Gift_cardid total NO SO An
integer that
assigns a given
gift card
to the payment
method

Table 10: Payment Table


Field name Field type Is the field there? Is value Description

required? Is
unique?
Machine Translated by Google

Id_payment total SO SO Internal


payment
identifier
Payment_date Sign-time SO SO
Determining date
moment
payments
Payment_methodid total SO SO An
integer that
assigns a given
payment method
to the
payment
Payment_plansid total SO SO An
integer that
assigns a given
payment plan to
a payment

Table 11: Payment_plans Table


Field name Field type Is the field there? Is value Description

required? Is
unique?
Id_payment_plans total SO SO Internal
identifier
payment_plans
name Characteristic SO SO A string
(max.45) specifying
the name of the plan
price total SO SO An
integer
specifying the price
plan

Table 12: Gift_card Table


Field name Field type Is the field there? Is value Description

required? Is
unique?
Id_gift_card total SO SO Internal
identifier
gift_card
code Character(max.15) SO SO A string
specifying the
gift
card code
Machine Translated by Google

Table 13: Series Table

Field Name Field Type Whether the field existsIs the value unique? Description

required?
Id_serie int4 so so Internal
ID
client
title Varchar So NO String of characters
(100) defining
title of the movie

poster Varchar so NO String of characters


(100) defining
publisher
production_year int4 so NO Number
specifying the date
production
age_category int4 so NO integer
being the key
alien. Refers
to the table
age_category
season_number int4 so NO Number
determining quantity
seasons
adding_date date so NO Determining date
date added to
platforms

Table 14: Episode Table


Field name Field Type Whether the field exists Is there value Description

required? unique?
id_episode int4 So So Internal
ID
episode
episode_title Varchar(100) So NO String of characters
specifying the title
episode
season int4 so so Number
determining
season until

which one belongs


episode
about Varchar(500) NO NO String of characters
Machine Translated by Google

describing
episode
path Varchar(100) So So String of characters
determining
file path
episode
number_of_episode int4 So NO Number
determining
episode number
serieid int4 So NO Number
whole
being the key
alien. Refers
to the table
series

How_long int so NO Number


defining
length of the section
in minutes

Tabela 15: Tabela Age_category


Field name Field type Is the field there? Is value description

required? Is
unique?

id_age_category int4 SO SO Internal


ID
category
age
name Varchar(100) SO SO Category description
age

Table 16: Device_type Table


Field name Field type Is the field there? Is value description

required? Is
unique?
Id_device_type int4 SO SO Internal
ID
device type
Device_type_name Varchar(255) SO NO Type description

devices
Machine Translated by Google

Table 17: Device Table

Field name Field type Is the field required? Is value Description

is it unique?

Id_device Int4 So So Internal


ID
devices

Device_name Varchar(255) So NO String of characters


determining
name
devices
Ip_address Varchar(20) So NO String of characters
defining
address ip
devices
Device_typeid int4 so NO Number
whole
being the key
alien. Refers
to the table
device_type

regions int4 so NO Number


whole
being the key
alien. Refers
to the table
region
Machine Translated by Google

6. Description of the database installation


The database engine of choice is PostgreSQL. The choice was unanimous and supported by many
advantages. First of all, PostgreSQL is characterized by high stability and simplicity of operation.
Moreover, it shows good performance, especially when the database is full of many records, and ultimately
Netflix may actually have a lot of data. Moreover, it is an Open Source project, so it can be freely used
and modified. Finally, we took one more thing into account, and that is the fact that Netflix itself uses
PostgreSQL.

The database was installed on the GNU/ Linux Pop!_OS 20.10 system using the pgAdmin 4 graphical
user interface tool.

First we need to install the database engine. The fastest and most universal way is to use the
terminal. Launch the terminal and enter the command sudo apt install postgresql.

Photo 4: Installing PostgreSQL in the terminal

Then install the pgAdmin 4 tool. You can also enter the appropriate commands. First, we add the
repository and then run the installation. The commands look like this:

sudo curl https:// www.pgadmin.org/ static/ packages_pgadmin_org.pub | sudo apt-key add


sudo sh -c 'echo "deb https:// ftp.postgresql.org/ pub/ pgadmin/ pgadmin4/ apt/ $(lsb_release -cs)
Machine Translated by Google

pgadmin4 main" > / etc/ apt/ sources.list.d/ pgadmin4.list && apt update'
sudo apt install pgadmin4

After this step, just run PostgreSQL by typing sudo -i -u postgres.


A command line will be launched with the privileges of the "postgres" user. By entering psql we gain
access to the PostgreSQL command line.

Photo 5: PostgreSQL command line

Using appropriate commands, we can also create a new user.

At this point you can go to the pgAdmin 4 tool. The application should automatically establish a
connection to the server. If not, you must manually enter the established username and
password. After a while, a notification should appear informing you about the connection.
Machine Translated by Google

From the tree on the left, select "Databases" and select "Create -> Database".
name the database "Netflix".

Photo 6: Creating a new database

Then you need to expand the branch with the new database and move to the public schema.
Here, right-click and select "Query Tool". The command line will start. You need to paste the SQL
code that creates the entire database structure. After a while, all tables with relationships
should be created. You can also use the "Generate ERD" option to preview the entity relationship diagram.
Machine Translated by Google

Photo 7: Creating tables and relationships in the database

Photo 8: Preview of the generated ERD diagram

Then you need to use the previously opened "Query Tool" to enter data into the tables.
The appropriate order of addition is given below.
Machine Translated by Google

7. SQL code needed to create the database


Below is the SQL code.

CREATE TABLE film (id_Film int4 NOT NULL, title varchar(100) NOT NULL, how_long int4
NOT NULL, poster varchar(100) NOT NULL, production_year date NOT NULL, path_to_file
varchar(100) NOT NULL UNIQUE, age_categoryid int4 NOT NULL, about varchar(500) NOT
NULL, add_time timestamp NOT NULL, PRIMARY KEY (id_Film));

CREATE TABLE genre (id_genre int4 NOT NULL, genre_name varchar(80) NOT NULL,
PRIMARY KEY (id_genre));

CREATE TABLE genre_movie(genreid int4 NOT NULL, MovieId int4 NOT NULL, genreMovie_id
int4 NOT NULL, PRIMARY KEY(genreid, MovieId, genreMovie_id));

CREATE TABLE age_category (id_age_category int4 NOT NULL, name varchar(80) NOT NULL,
PRIMARY KEY (id_age_category));

CREATE TABLE country (id_country int4 NOT NULL, country_name varchar(80) NOT NULL,
PRIMARY KEY (id_country));

CREATE TABLE film_country (Filmid int4 NOT NULL, countryid int4 NOT NULL,
id_filmCountry int4 NOT NULL, PRIMARY KEY (Filmid, countryid, id_filmCountry));

CREATE TABLE serie (id_serie int4 NOT NULL, title varchar(100) NOT NULL, poster
varchar(100) NOT NULL, production_year int4 NOT NULL, age_category int4 NOT NULL,
season_number int4 NOT NULL, adding_date date NOT NULL, PRIMARY KEY (id_serie));

CREATE TABLE series_genre(seriesid int4 NOT NULL, genreid int4 NOT NULL, series_idGenre
int4 NOT NULL, PRIMARY KEY(seriesid, genreid, series_idGenre));

CREATE TABLE serie_productionCountry (serieid int4 NOT NULL, countryid int4 NOT NULL,
id_serie_productionCountry int4 NOT NULL, PRIMARY KEY (serieid, countryid,
id_serie_productionCountry));

CREATE TABLE episode (id_episode int4 NOT NULL, episode_title varchar(100) NOT NULL,
season int4 NOT NULL, about varchar(500) NOT NULL, path varchar(100) NOT NULL UNIQUE,
number_of_episode int4 NOT NULL, serieid int4 NOT NULL, how_long int4 NOT NULL,
PRIMARY KEY (id_episode));

CREATE TABLE actor (id_actor int4 NOT NULL, name varchar(100) NOT NULL, lastname
varchar(100) NOT NULL, photo_path varchar(100) NOT NULL UNIQUE, PRIMARY KEY
(id_actor));

CREATE TABLE actor_Movie ( actorid int4 NOT NULL , Movieid int4 NOT NULL , actor_id Movie int4
NOT NULL, PRIMARY KEY (actors, Movies, id_actorFilm));

CREATE TABLE actor_series ( actorid int4 NOT NULL , seriesid int4 NOT NULL , actor_id_Series int4
NOT NULL, PRIMARY KEY (actorid, serieid, id_actorSerie));

CREATE TABLE "user" (id_user int4 NOT NULL, nick varchar(50) NOT NULL UNIQUE,
hash_passwd varchar(255) NOT NULL, salt varchar(255) NOT NULL, "e-mail" varchar(150) NOT
NULL UNIQUE, age date NOT NULL, countryid int4 NOT NULL, phone_number varchar(12),
PRIMARY KEY (id_user));
Machine Translated by Google

CREATE TABLE credit_card (id_credit_card int4 NOT NULL, card_number varchar(16) NOT
NULL, cvc varchar(3) NOT NULL, expiration_date varchar(5) NOT NULL, owner_name
varchar(255) NOT NULL, owner_lastname varchar(255) NOT NULL, PRIMARY KEY
(id_credit_card));

CREATE TABLE user_profiles (id_user_profile int8 NOT NULL, nickname varchar(45) NOT
NULL, profile_photosid int4 NOT NULL, Uzytkownikid int4 NOT NULL, is_adult bytea NOT
NULL, Languagesid int4 NOT NULL, FIlm_Wanted_to_watchid int4, Series_wanted_to_watchid
int4, PRIMARY KEY (id_user_profile));

CREATE TABLE profile_photos (id_profile_photos int4 NOT NULL, photo varchar(100) NOT
NULL, PRIMARY KEY (id_profile_photos));

CREATE TABLE profile_is_watching (id_session int4 NOT NULL, User_profilesid int8 NOT
NULL, Episode_serieid int4, Filmid int4, "date" timestamp NOT NULL, PRIMARY KEY
(id_session));

CREATE TABLE languages (id_languages int4 NOT NULL, language varchar(50) NOT NULL,
PRIMARY KEY (id_languages));

CREATE TABLE payment_plans (id_payment_plans int4 NOT NULL, name varchar(45) NOT
NULL, price int4 NOT NULL, PRIMARY KEY (id_payment_plans));

CREATE TABLE gift_card (id_gift_card int4 NOT NULL, code varchar(15) NOT NULL,
PRIMARY KEY (id_gift_card));

CREATE TABLE payment (id_payment int4 NOT NULL, payment_date timestamp NOT NULL,
payment_methodid int4 NOT NULL, payment_plansid int4 NOT NULL, PRIMARY KEY
(id_payment));

CREATE TABLE payment_method (id_payment_method int4 NOT NULL, credit_cardid int4 NOT
NULL, gift_cardid int4, PRIMARY KEY (id_payment_method));

CREATE TABLE user_payment_method (Userid int4 NOT NULL, payment_methodid int4 NOT
NULL, id_userPaymentMethod int4 NOT NULL, PRIMARY KEY (Userid, payment_methodid,
id_userPaymentMethod));

CREATE TABLE device (id_device int4 NOT NULL, device_name varchar(255) NOT NULL,
ip_address varchar(20) NOT NULL, device_typeid int4 NOT NULL, Regionid int4 NOT NULL,
PRIMARY KEY (id_device));

CREATE TABLE device_user (Deviceid int4 NOT NULL, userid int4 NOT NULL, id_device_user
int4 NOT NULL, last_used timestamp NOT NULL, PRIMARY KEY (Deviceid, userid,
id_device_user));

CREATE TABLE device_type (id_device_type int4 NOT NULL, device_type_name varchar(255)


NOT NULL, PRIMARY KEY (id_device_type));

CREATE TABLE Region (id_region int4 NOT NULL, name varchar(255) NOT NULL, countryid
int4 NOT NULL, PRIMARY KEY (id_region));

CREATE TABLE fIlm_Wanted_to_watch (id_FIlm_wanted_to_watch SERIAL NOT NULL,


PRIMARY KEY (id_FIlm_wanted_to_watch));
Machine Translated by Google

CREATE TABLE series_wanted_to_watch (id_series_wanted_to_watch SERIAL NOT NULL,


PRIMARY KEY (id_series_wanted_to_watch));

CREATE TABLE film_FIlm_Wanted_to_watch (Filmid int4 NOT NULL,


FIlm_Wanted_to_watchid int4 NOT NULL, id_FilmFilmWantedtoWatch int4 NOT NULL,
PRIMARY KEY (Filmid, FIlm_Wanted_to_watchid, id_FilmFilmWantedtoWatch));

CREATE TABLE serie_series_wanted_to_watch (Serieid int4 NOT NULL,


Series_wanted_to_watchid int4 NOT NULL, id_SerieSeriesWantedtoWatch int4 NOT NULL,
PRIMARY KEY (Serieid, Series_wanted_to_watchid, id_SerieSeriesWantedtoWatch));

CREATE TABLE watching_history (id_watchingHistory int4 NOT NULL,


profile_is_watchingid_session int4 NOT NULL, stop_watching_moment varchar(50) NOT NULL,
PRIMARY KEY (id_watchingHistory));

ALTER TABLE genre_film ADD CONSTRAINT FKgenre_film71472 FOREIGN KEY (genreid)


REFERENCES genre (id_genre) ON UPDATE Cascade ON DELETE No action;

ALTER TABLE genre_film ADD CONSTRAINT FKgenre_film139093 FOREIGN KEY (Filmid)


REFERENCES film (id_Film) ON UPDATE Cascade ON DELETE Set default;

ALTER TABLE film ADD CONSTRAINT FKfilm23698 FOREIGN KEY (age_categoryid)


REFERENCES age_category (id_age_category) ON UPDATE Cascade ON DELETE Set default;

ALTER TABLE film_country ADD CONSTRAINT FKfilm_count414041 FOREIGN KEY


(Films) REFERENCES film (id_Film) ON UPDATE Cascade ON DELETE No action;

ALTER TABLE film_country ADD CONSTRAINT FKfilm_count669570 FOREIGN KEY (countryid)


REFERENCES country (id_country) ON UPDATE Cascade ON DELETE No action;

ALTER TABLE serie ADD CONSTRAINT FKserie922359 FOREIGN KEY (age_category)


REFERENCES age_category (id_age_category) ON UPDATE Cascade ON DELETE Set null;

ALTER TABLE serie_genre ADD CONSTRAINT FKserie_genr558468 FOREIGN KEY (serieid)


REFERENCES serie (id_serie) ON UPDATE No action ON DELETE No action;

ALTER TABLE serie_genre ADD CONSTRAINT FKserie_genr703857 FOREIGN KEY (genreid)


REFERENCES genre (id_genre) ON UPDATE Cascade ON DELETE No action;

ALTER TABLE serie_productionCountry ADD CONSTRAINT FKserie_prod318377 FOREIGN


KEY (serieid) REFERENCES serie (id_serie) ON UPDATE Cascade ON DELETE No action;

ALTER TABLE serie_productionCountry ADD CONSTRAINT FKserie_prod379201 FOREIGN


KEY (countryid) REFERENCES country (id_country) ON UPDATE Cascade ON DELETE No action;

ALTER TABLE episode ADD CONSTRAINT FKepisode293403 FOREIGN KEY (serieid)


REFERENCES serie (id_serie) ON UPDATE Cascade ON DELETE Cascade;

ALTER TABLE actor_Film ADD CONSTRAINT FKactor_Film524896 FOREIGN KEY (actorid)


REFERENCES actor (id_actor) ON UPDATE Cascade ON DELETE No action;

ALTER TABLE actor_Film ADD CONSTRAINT FKactor_Film474332 FOREIGN KEY (Filmid)


REFERENCES film (id_Film) ON UPDATE Cascade ON DELETE No action;
Machine Translated by Google

ALTER TABLE actor_serie ADD CONSTRAINT FKactor_seri794137 FOREIGN KEY (actorid)


REFERENCES actor (id_actor) ON UPDATE Cascade ON DELETE No action;

ALTER TABLE actor_serie ADD CONSTRAINT FKactor_seri428205 FOREIGN KEY (serieid)


REFERENCES serie (id_serie) ON UPDATE Cascade ON DELETE No action;

ALTER TABLE "user" ADD CONSTRAINT FKuser271711 FOREIGN KEY (countryid)


REFERENCES country (id_country) ON UPDATE Cascade ON DELETE No action;

ALTER TABLE user_profiles ADD CONSTRAINT FKuser_profi110750 FOREIGN KEY (profile_photosid)


REFERENCES profile_photos (id_profile_photos) ON UPDATE No action ON
DELETE Set default;

ALTER TABLE user_profiles ADD CONSTRAINT FKuser_profi985153 FOREIGN KEY


(Uzytkownikid) REFERENCES "user" (id_user);

ALTER TABLE profile_is_watching ADD CONSTRAINT FKprofile_is79705 FOREIGN KEY


(User_profilesid) REFERENCES user_profiles (id_user_profile) ON UPDATE Cascade ON
DELETE Cascade;

ALTER TABLE profile_is_watching ADD CONSTRAINT FKprofile_is443338 FOREIGN KEY


(Films) REFERENCES film (id_Film) ON UPDATE No action ON DELETE No action;

ALTER TABLE profile_is_watching ADD CONSTRAINT FKprofile_is993269 FOREIGN KEY


(Episode_serieid) REFERENCES episode (id_episode) ON UPDATE No action ON DELETE No action;

ALTER TABLE user_profiles ADD CONSTRAINT FKuser_profi624622 FOREIGN KEY


(Languagesid) REFERENCES languages (id_languages) ON UPDATE No action ON DELETE Set
default;

ALTER TABLE payment_method ADD CONSTRAINT FKpayment_me53348 FOREIGN KEY (credit_cardid)


REFERENCES credit_card (id_credit_card) ON UPDATE Cascade ON DELETE
Set default;

ALTER TABLE payment_method ADD CONSTRAINT FKpayment_me658051 FOREIGN KEY (gift_cardid)


REFERENCES gift_card (id_gift_card) ON UPDATE Cascade ON DELETE
Cascade;

ALTER TABLE payment ADD CONSTRAINT FKpayment199132 FOREIGN KEY


(payment_methodid) REFERENCES payment_method (id_payment_method) ON UPDATE
Cascade ON DELETE No action;

ALTER TABLE payment ADD CONSTRAINT FKpayment7431 FOREIGN KEY (payment_plansid)


REFERENCES payment_plans (id_payment_plans) ON UPDATE Cascade ON
DELETE No action;

ALTER TABLE user_payment_method ADD CONSTRAINT FKuser_payme781594 FOREIGN


KEY (Userid) REFERENCES "user" (id_user) ON UPDATE Cascade ON DELETE No action;

ALTER TABLE user_payment_method ADD CONSTRAINT FKuser_payme381628 FOREIGN


KEY (payment_methodid) REFERENCES payment_method (id_payment_method) ON UPDATE
Cascade ON DELETE No action;
Machine Translated by Google

ALTER TABLE device_user ADD CONSTRAINT FKdevice_use333048 FOREIGN KEY


(Deviceid) REFERENCES device (id_device) ON UPDATE Cascade ON DELETE No action;

ALTER TABLE device_user ADD CONSTRAINT FKdevice_use421854 FOREIGN KEY (userid)


REFERENCES "user" (id_user) ON UPDATE Cascade ON DELETE Cascade;

ALTER TABLE device ADD CONSTRAINT FKdevice918743 FOREIGN KEY (device_typeid)


REFERENCES device_type (id_device_type) ON UPDATE Cascade ON DELETE No action;

ALTER TABLE Region ADD CONSTRAINT FKRegion257814 FOREIGN KEY (countryid)


REFERENCES country (id_country) ON UPDATE Cascade ON DELETE No action;

ALTER TABLE device ADD CONSTRAINT FKdevice920182 FOREIGN KEY (Regionid)


REFERENCES Region (id_region) ON UPDATE Cascade ON DELETE No action;

ALTER TABLE user_profiles ADD CONSTRAINT FKuser_profi295817 FOREIGN KEY


(FIlm_Wanted_to_watchid) REFERENCES fIlm_Wanted_to_watch (id_FIlm_wanted_to_watch)
ON UPDATE Cascade ON DELETE Cascade;

ALTER TABLE user_profiles ADD CONSTRAINT FKuser_profi532880 FOREIGN KEY


(Series_wanted_to_watchid) REFERENCES series_wanted_to_watch (id_series_wanted_to_watch)
ON UPDATE Cascade ON DELETE Set null;

ALTER TABLE film_FIlm_Wanted_to_watch ADD CONSTRAINT FKfilm_FIlm_791760


FOREIGN KEY (Filmid) REFERENCES film (id_Film) ON UPDATE Cascade ON DELETE No action;

ALTER TABLE film_FIlm_Wanted_to_watch ADD CONSTRAINT FKfilm_FIlm_844480


FOREIGN KEY (FIlm_Wanted_to_watchid) REFERENCES fIlm_Wanted_to_watch
(id_FIlm_wanted_to_watch) ON UPDATE Cascade ON DELETE Cascade;

ALTER TABLE serie_series_wanted_to_watch ADD CONSTRAINT FKserie_seri134189


FOREIGN KEY (Serieid) REFERENCES serie (id_serie) ON UPDATE No action ON DELETE
No action;

ALTER TABLE serie_series_wanted_to_watch ADD CONSTRAINT FKserie_seri73619


FOREIGN KEY (Series_wanted_to_watchid) REFERENCES series_wanted_to_watch
(id_series_wanted_to_watch) ON UPDATE Cascade ON DELETE Cascade;

ALTER TABLE watching_history ADD CONSTRAINT FKwatching_h70704 FOREIGN KEY


(profile_is_watchingid_session) REFERENCES profile_is_watching (id_session) ON UPDATE
Cascade ON DELETE No action;
Machine Translated by Google

8. Filling tables with data


Filling in the data has been presented in the right order, so no problems should arise.

1. age_category

INSERT INTO public.age_category(name) VALUES ('all');

INSERT INTO public.age_category(name) VALUES ('7+');

INSERT INTO public.age_category(name) VALUES ('13+');

INSERT INTO public.age_category(name) VALUES ('16+');

INSERT INTO public.age_category(name) VALUES ('18+');

2. country

INSERT INTO public.country(country_name) VALUES ('Polska');

INSERT INTO public.country(country_name) VALUES ('Anglia');

INSERT INTO public.country(country_name) VALUES ('Hiszpania');

INSERT INTO public.country(country_name) VALUES ('Rosja');

INSERT INTO public.country(country_name) VALUES ('Wlochy');

INSERT INTO public.country(country_name) VALUES ('Niemcy');

INSERT INTO public.country(country_name) VALUES ('Francja');

INSERT INTO public.country(country_name) VALUES ('Grecja');

INSERT INTO public.country(country_name) VALUES ('USA');

INSERT INTO public.country(country_name) VALUES ('Szwecja');


Machine Translated by Google

3. device_type

INSERT INTO public.device_type(device_type_name) VALUES ('smartfon');

INSERT INTO public.device_type(device_type_name) VALUES ('tablet');

INSERT INTO public.device_type(device_type_name) VALUES ('komputer');

INSERT INTO public.device_type(device_type_name) VALUES ('laptop');

INSERT INTO public.device_type(device_type_name) VALUES ('telewizor');

4. series

INSERT INTO public.serie(title,poster,production_year,age_category,season_number,adding_date)


VALUES ('Blacklist','\posters\series\czarna_lista.jpg',2015,4,8,'2020-12-12');

INSERT INTO public.serie(title,poster,production_year,age_category,season_number,adding_date)


VALUES ('Breaking Bad','\plakaty\seriale\breaking_bad.jpg',2013,4,5,'2020-11-11');

INSERT INTO public.serie(title,poster,production_year,age_category,season_number,adding_date)


VALUES ('House of Cards','\plakaty\seriale\house_of_cards.jpg',2014,4,6,'2021-11-12');

INSERT INTO public.serie(title,poster,production_year,age_category,season_number,adding_date)


VALUES ('Formula 1: The Ride for Your Life','\posters\series\formula1.jpg',2018,4,3,'2019-01-01');

INSERT INTO public.serie(title,poster,production_year,age_category,season_number,adding_date)


VALUES ('Homeland','\plakaty\seriale\homeland.jpg',2011,4,8,'2018-04-04');

INSERT INTO public.serie(title,poster,production_year,age_category,season_number,adding_date)


VALUES ('Lake of dreams','\posters\series\jezioro_marzeÿ.jpg',2012,3,6,'2018-01-01');

INSERT INTO public.serie(title,poster,production_year,age_category,season_number,adding_date)


VALUES ('H2O, just a drop','\posters\series\h2o_wystarczy_kropla.jpg',2013,2,3,'2021-04-
04');
Machine Translated by Google

INSERT INTO public.serie(title,poster,production_year,age_category,season_number,adding_date)


VALUES ('Paw Patrol','\posters\series\psi_patrol.jpg',2012,1,3,'2020-03-06');

INSERT INTO public.serie(title,poster,production_year,age_category,season_number,adding_date)


VALUES ('Peaky Blinders','\plakaty\seriale\peaky_blinders.jpg',2015,4,5,'2019-06-06');

INSERT INTO public.serie(title,poster,production_year,age_category,season_number,adding_date)


VALUES ('Riverdale','\plakaty\seriale\peaky_blinders.jpg',2019,4,5,'2020-10-10');

5. gift_card

INSERT INTO public.gift_card(code) VALUES ('9322-0012-6798');

INSERT INTO public.gift_card(code) VALUES ('8254-1860-3617');

INSERT INTO public.gift_card(code) VALUES ('1047-8943-5679');

INSERT INTO public.gift_card(code) VALUES ('5079-1759-6826');

INSERT INTO public.gift_card(code) VALUES ('6748-4870-1285');

INSERT INTO public.gift_card(code) VALUES ('9016-5870-4658');

INSERT INTO public.gift_card(code) VALUES ('6591-7920-1476');

INSERT INTO public.gift_card(code) VALUES ('4769-0175-2347');

INSERT INTO public.gift_card(code) VALUES ('0386-2856-1293');

INSERT INTO public.gift_card(code) VALUES ('9754-8045-1768');

6. languages
Machine Translated by Google

INSERT INTO public.languages(language) VALUES ('Polski');

INSERT INTO public.languages(language) VALUES ('English(British)');

INSERT INTO public.languages(language) VALUES ('Hiszpanski');

INSERT INTO public.languages(language) VALUES ('Rosyjski');

INSERT INTO public.languages(language) VALUES ('Wloski');

INSERT INTO public.languages(language) VALUES ('Niemiecki');

INSERT INTO public.languages(language) VALUES ('Francuski');

INSERT INTO public.languages(language) VALUES ('Grecki');

INSERT INTO public.languages(language) VALUES('English(American)');

INSERT INTO public.languages(language) VALUES ('Szwedzki');

7. payment_plans

INSERT INTO public.payment_plans(name,price) VALUES ('Podstawowy',34);

INSERT INTO public.payment_plans(name,price) VALUES ('Standard',43);

INSERT INTO public.payment_plans(name,price) VALUES ('Premium',52);

INSERT INTO public.payment_plans(name,price) VALUES ('Mobilny',30);

INSERT INTO public.payment_plans(name,price) VALUES ('Ilosciowy',28);

8. episode
Machine Translated by Google

INSERT INTO
public.episode(episode_title,season,about,path,number_of_episode,serieid,how_long,FIELD8)
VALUES ('Freelancer (No. 145)',1,'Liz and Red track down a murderer who fakes disasters to cover
up his murders. The Department of Justice tries hard to understand Red's
motives.','series\blacklist\blacklistS1E2.mkv',2 ,1,40,NULL);
INSERT INTO
public.episode(episode_title,season,about,path,number_of_episode,serieid,how_long,FIELD8)
VALUES ('Wuijing(No. 84)',1,'Liz and Red go incognito to neutralize an assassin
decimating the ranks of CIA agents. Tom asks Liz about the man who attacked him.','series\
blacklist\blacklistS1E3.mkv',3,1,42,NULL);
INSERT INTO
public.episode(episode_title,season,about,path,number_of_episode,serieid,how_long,FIELD8)
VALUES ('Pilot',1,'A high school chemistry teacher learns that he has terminal lung cancer. To provide
for his family, he turns to producing and distributing methamphetamine.','series\
breaking bad\sezon1\breakingbadS1E1.mkv',1,2,58,NULL);
INSERT INTO
public.episode(episode_title,season,about,path,number_of_episode,serieid,how_long,FIELD8)
VALUES ('Bird in a Cage',1,'After their first failed deal, Walt and Jesse have to get rid of two dead
bodies. Meanwhile, Skyler suspects that her husband is up to something.','series\breaking bad\season 1\
breakingbadS1E2.mkv',2,2,48,NULL);
INSERT INTO
public.episode(episode_title,season,about,path,number_of_episode,serieid,how_long,FIELD8)
VALUES ('Chapter 1',1,'When the newly elected president does not keep his promise, Frank and
Claire decide to forget about loyalty and all rules.','series\house of cards\season 1\
houseofcardsS1E1.mkv',1,3,NULL,NULL);
INSERT INTO
public.episode(episode_title,season,about,path,number_of_episode,serieid,how_long,FIELD8)
VALUES ('Chapter 2',1,'With the help of a young journalist, Zoe Barnes, Frank publicizes a case that
causes a stir in the White House. Claire makes drastic cuts to the foundation.','series\
houseofcardsS1E1\season1\houseofcardsS1E2.mkv',2,3,49,NULL);
INSERT INTO
public.episode(episode_title,season,about,path,number_of_episode,serieid,how_long,FIELD8)
VALUES ('Let's go!',2,'The new Formula 1 season opens with the Australian Grand Prix. Ten teams
are fiercely competing for a place on the podium.','series\formula1\season2\
formula1S2E1.mkv',1,4,33,NULL);
INSERT INTO
public.episode(episode_title,season,about,path,number_of_episode,serieid,how_long,FIELD8)
VALUES ('Grace',1,'A Saudi prince is probably financing terrorist activities, and an undercover agent
working in his entourage provides Carrie with evidence confirming this.','series\
homeland\sezon1\homelandS1E1.mkv',1,5,55,NULL);
INSERT INTO
public.episode(episode_title,season,about,path,number_of_episode,serieid,how_long,FIELD8)
Machine Translated by Google

VALUES ('Baby',1,'Pacey and Tamara's affair is revealed. Bessie giving birth must enlist the
help of Grandma Jen.','seriale\jezioromarzen\season 1\jezioromarzen.mkv',1,6,42,NULL);
INSERT INTO
public.episode(episode_title,season,about,path,number_of_episode,serieid,how_long,FIELD8)
VALUES ('Are they sharks?',1,'The girls find out that sea turtles get caught in fishermen's nets. Rikki
and Emma rush to help, which makes the fishermen think that they are being attacked by sharks.','series\
h2o\sezon1\h2oS1E3.mkv',3,7,25,NULL);

INSERT INTO
public.episode(episode_title,season,about,path,number_of_episode,serieid,how_long,FIELD8)
VALUES ('Pups save the blimp/Pups save the cooking competition',1,'Mayor Humdinger thinks
that the airship affects the weather, so he decides to hijack it. Adventure Bay and Misty Village compete
in a cooking show.','series\psipatrol\season1\psipatrolS1E1',1,8,23,NULL);
INSERT INTO
public.episode(episode_title,season,about,path,number_of_episode,serieid,how_long,FIELD8)
VALUES ('Episode 6',1,'Thomas prepares to remove Kimber from power, but family secrets that
come to light and an obsessed Campbell may stand in his way.','series\peakyblinders\season
1\peakyblindersS1E6', 6,9,54,NULL);

INSERT INTO
public.episode(episode_title,season,about,path,number_of_episode,serieid,how_long,FIELD8)
VALUES ('Chapter Twenty-Three: The School Jungle',1,'When students from Southside School transfer
to Riverdale High, a cultural conflict breaks out. The FBI talks to Archie.
Betty searches for her long-lost brother.','series\riverdale\season 1\
riverdaleS1E10',10,10,42,NULL);

9. region

INSERT INTO public.Region(name,countryid) VALUES('ÿwiÿtokrzyskie Voivodeship',1);

INSERT INTO public.Region(name,countryid) VALUES('Opole Voivodeship',1);

INSERT INTO public.Region(name,countryid) VALUES('Lesser Poland Voivodeship',1);

INSERT INTO public.Region(name,countryid) VALUES ('Andaluzja',3);

INSERT INTO public.Region(name,countryid) VALUES ('Katalonia',3);

INSERT INTO public.Region(name,countryid) VALUES ('Saksonia',6);

INSERT INTO public.Region(name,countryid) VALUES ('Brema',6);

INSERT INTO public.Region(name,countryid) VALUES ('Sycylia',5);


Machine Translated by Google

INSERT INTO public.Region(name,countryid) VALUES ('Toskania',5);

INSERT INTO public.Region(name,countryid) VALUES ('Abruzja',5);

10. profile_photos

INSERT INTO public.profile_photos(photo) VALUES ('\users\profilepictures\wozek.jpg');

INSERT INTO public.profile_photos(photo) VALUES ('\users\profilepictures\pingwin.jpg');

INSERT INTO public.profile_photos(photo) VALUES ('\users\profilepictures\trol.jpg');

INSERT INTO public.profile_photos(photo) VALUES ('\users\profilepictures\balwan.jpg');

INSERT INTO public.profile_photos(photo) VALUES ('\users\profilepictures\maska.jpg');

INSERT INTO public.profile_photos(photo) VALUES ('\users\profilepictures\donut.jpg');

INSERT INTO public.profile_photos(photo) VALUES ('\users\profilepictures\slonce.jpg');

INSERT INTO public.profile_photos(photo) VALUES ('\users\profilepictures\ksiezyc.jpg');

INSERT INTO public.profile_photos(photo) VALUES ('\users\profilepictures\mars.jpg');

INSERT INTO public.profile_photos(photo) VALUES ('\users\profilepictures\ziemia.jpg');

11. Device
Machine Translated by Google

INSERT INTO public.device(device_name,ip_address,device_typeid,regionid) VALUES ('Chrome PC


(Cadmium)','83.26.217.57',3,1);

INSERT INTO public.device(device_name,ip_address,device_typeid,regionid) VALUES ('Safari MAC


(Cadmium)','83.28.89.207',4,2);

INSERT INTO public.device(device_name,ip_address,device_typeid,regionid) VALUES ('Apple iPhone


XR','83.28.89.20',1,3);

INSERT INTO public.device(device_name,ip_address,device_typeid,regionid) VALUES ('Samsung


2018 Kant-M2 UHD TV (1.5G) Smart TV','31.0.123.52',5,4);

INSERT INTO public.device(device_name,ip_address,device_typeid,regionid) VALUES ('Philips 2K18


PHTV18AMT1 Smart TV','31.0.123.52',5,5);

INSERT INTO public.device(device_name,ip_address,device_typeid,regionid) VALUES ('Apple iPhone 11


Pro','89.64.25.20',1,6);

INSERT INTO public.device(device_name,ip_address,device_typeid,regionid) VALUES ('Netflix Windows


App','95.156.244.211',3,7);

INSERT INTO public.device(device_name,ip_address,device_typeid,regionid) VALUES ('LG 2015


MTK A5LR Smart TV','193.186.206.90',5,8);

INSERT INTO public.device(device_name,ip_address,device_typeid,regionid) VALUES ('Philips TPV 2K18


MT5802 Smart TV','185.122.99.100',5,9);

INSERT INTO public.device(device_name,ip_address,device_typeid,regionid) VALUES


('DefaultWidevineAndroidPhone','37.248.156.19',1,10);

12. genre

INSERT INTO public.genre(genre_name) VALUES ('dramat');

INSERT INTO public.genre(genre_name) VALUES ('komedia');

INSERT INTO public.genre(genre_name) VALUES ('thriller');

INSERT INTO public.genre(genre_name) VALUES ('sci-fi');

INSERT INTO public.genre(genre_name) VALUES ('animowany');

INSERT INTO public.genre(genre_name) VALUES ('historyczny');

INSERT INTO public.genre(genre_name) VALUES ('akcji');

INSERT INTO public.genre(genre_name) VALUES ('edukacyjny');


Machine Translated by Google

INSERT INTO public.genre(genre_name) VALUES ('dokumentalny');

INSERT INTO public.genre(genre_name) VALUES ('biograficzny');

13. Film

INSERT INTO
public.film(title,how_long,poster,production_year,path_to_file,age_categoryid,about,add_time)
VALUES ('Kingsman: The
Secret Service',130,'/posters/filmy/kingsman.jpg','2014-05-17','/filmy/kingsman2014.nfv','2','British-
American spy film' ,'2015-05-14 16:30:00');
INSERT INTO

public.film(title,how_long,poster,production_year,path_to_file,age_categoryid,about,add_time)
VALUES ('Avengers:
Endgame',182,'/posters/filmy/avengers.jpg','2019-07-26','/filmy/avengersEndgame.nfv','4','American
science fiction action film from 2019 year based on a series of comic books about a
group of superheroes','2019-06-25 19:30:00');
INSERT INTO
public.film(title,how_long,poster,production_year,path_to_file,age_categoryid,about,add_time)
VALUES ('X-Men: Dark
Phoenix',114,'/posters/filmy/phoenix.jpg','2019-08-10','/filmy/phoenix.nfv','3','American science
fiction action film based on a series of comic books about a group of superheroes','2019-08-
20 18:00:01');
INSERT INTO
public.film(title,how_long,poster,production_year,path_to_file,age_categoryid,about,add_time)
VALUES ('Star Wars: Episode II – Attack of the Clones',142,'/plakaty/filmy/atakklonow.jpg','2002-02-
10','/filmy/atakklonow.nfv','5','chronologically the second part of the Star Wars saga','2014-11-14
15:25:00');
Machine Translated by Google

INSERT INTO
public.film(title,how_long,poster,production_year,path_to_file,age_categoryid,about,add_time)
VALUES ('Star Wars: Episode I - The Phantom
Menace',136,'/plakaty/filmy/mzdrowiewidmo.jpg','1999-12-06','/filmy/
shadowmena.nfv','3','chronologically the first part of the Star Wars saga','2014-10-26 16:45:10');

INSERT INTO
public.film(title,how_long,poster,production_year,path_to_file,age_categoryid,about,add_time)
VALUES ('Niezgoda',139,'/plakaty/filmy/niezgoda.jpg','2014-05-18','/filmy/
incongruent.nfv','1','American action adventure film with elements of sociological
fantasy','2018-08-19 18:30:00');

INSERT INTO
public.film(title,how_long,poster,production_year,path_to_file,age_categoryid,about,add_time)
VALUES ('Maze Runner',113,'/plakaty/filmy/labirynt.jpg','2014-05-11','/filmy/
labirynt.nfv','4','American science fiction film directed by Wes Ball','2018-
09-23 20:05:00');

INSERT INTO
public.film(title,how_long,poster,production_year,path_to_file,age_categoryid,about,add_time)
VALUES ('Maze Runner: The Death
Cure',143,'/plakaty/filmy/labirynt_lek.jpg','2018-09-04','/filmy/labirynt_lek.nfv','2','American science fiction
film from 2018 directed by Wes Ball','2021-05-03 20:30:00');

INSERT INTO

public.film(title,how_long,poster,production_year,path_to_file,age_categoryid,about,add_time)
VALUES ('The Unbreakables',332,'/plakaty/niepowiedzalni.jpg','2010-04-22','/filmy/
indestructible.nfv','1','The Expendables is an American action thriller series','2013-05-12 15:45:00');

INSERT INTO
public.film(title,how_long,poster,production_year,path_to_file,age_categoryid,about,add_time)
VALUES ('Men in Black',98,'/plakaty/filmy/faceciwczerni.jpg','1997-09-20','/filmy/
faceciwczerni.nfv','2','Men in Black is a series of American science fiction action comedies','2012-06-
18 20:30:05');

14. serie_genre

INSERT INTO public.serie_genre(serieid,genreid) VALUES (9,1);

INSERT INTO public.serie_genre(serieid,genreid) VALUES (10,2);


Machine Translated by Google

INSERT INTO public.serie_genre(serieid,genreid) VALUES (11,3);

INSERT INTO public.serie_genre(serieid,genreid) VALUES (12,4);

INSERT INTO public.serie_genre(serieid,genreid) VALUES (13,5);

INSERT INTO public.serie_genre(serieid,genreid) VALUES (14,6);

INSERT INTO public.serie_genre(serieid,genreid) VALUES (15,7);

INSERT INTO public.serie_genre(serieid,genreid) VALUES (16,6);

INSERT INTO public.serie_genre(serieid,genreid) VALUES (17,9);

INSERT INTO public.serie_genre(serieid,genreid) VALUES (18,1);

15. genre_film

INSERT INTO public.genre_film(genreid,Films) VALUES (1,1);

INSERT INTO public.genre_film(genreid,Films) VALUES (3,5);

INSERT INTO public.genre_film(genreid,Films) VALUES (3,2);

INSERT INTO public.genre_film(genreid,Films) VALUES (4,3);

INSERT INTO public.genre_film(genreid,Films) VALUES (5,4);

INSERT INTO public.genre_film(genreid,Films) VALUES (2,4);

INSERT INTO public.genre_film(genreid,Films) VALUES (1,6);

INSERT INTO public.genre_film(genreid,Films) VALUES (4,5);

INSERT INTO public.genre_film(genreid,Films) VALUES (5,10);

INSERT INTO public.genre_film(genreid,Films) VALUES (3,8);

16. actor
Machine Translated by Google

INSERT INTO public.actor(name,lastname,photo_path) VALUES ('James','Spader','aktorzy\


jamesspader.jpg');

INSERT INTO public.actor(name,lastname,photo_path) VALUES ('Bryan','Cranston','aktorzy\


bryancranston.jpg');

INSERT INTO public.actor(name,lastname,photo_path) VALUES ('Kevin','Spacey','aktorzy\


kevinspacey.jpg');

INSERT INTO public.actor(name,lastname,photo_path) VALUES ('Charles','Leclerc','aktorzy\


charlesleclerc.jpg');

INSERT INTO public.actor(name,lastname,photo_path) VALUES ('Claire','Danes','aktorzy\


clairedanes.jpg');

INSERT INTO public.actor(name,lastname,photo_path) VALUES ('Katie','Holmes','aktorzy\


katieholmes.jpg');

INSERT INTO public.actor(name,lastname,photo_path) VALUES ('Cariba','Heine','aktorzy\


caribaheine.jpg');

INSERT INTO public.actor(name,lastname,photo_path) VALUES ('Devan','Cohen','aktorzy\


devancohen.jpg');

INSERT INTO public.actor(name,lastname,photo_path) VALUES ('Helen','McCrory','aktorzy\


helenmccrory.jpg');

INSERT INTO public.actor(name,lastname,photo_path) VALUES ('Lili','Reinhart','aktorzy\


lilireinhart.jph');

17. actor_film

INSERT INTO public.actor_film(actorId,FilmId) VALUES (5,5);

INSERT INTO public.actor_film(actorId,FilmId) VALUES (7,3);

INSERT INTO public.actor_film(actorId,FilmId) VALUES (8,1);

INSERT INTO public.actor_film(actorId,FilmId) VALUES (2,5);

INSERT INTO public.actor_film(actorId,FilmId) VALUES (3,8);

INSERT INTO public.actor_film(actorId,FilmId) VALUES (9,10);

INSERT INTO public.actor_film(actorId,FilmId) VALUES (9,4);

INSERT INTO public.actor_film(actorId,FilmId) VALUES (2,7);


Machine Translated by Google

INSERT INTO public.actor_film(actorId,FilmId) VALUES (8,8);

INSERT INTO public.actor_film(actorId,FilmId) VALUES (5,2);

18. series_actor

INSERT INTO public.actor_series(actorid,seriesid) VALUES (1,9);

INSERT INTO public.actor_series(actorid,seriesid) VALUES (2,10);

INSERT INTO public.actor_series(actorid,seriesid) VALUES (3,11);

INSERT INTO public.actor_series(actorid,seriesid) VALUES (4,12);

INSERT INTO public.actor_series(actorid,seriesid) VALUES (5,13);

INSERT INTO public.actor_series(actorid,seriesid) VALUES (6,14);

INSERT INTO public.actor_series(actorid,seriesid) VALUES (7,15);

INSERT INTO public.actor_series(actorid,seriesid) VALUES (8,16);

INSERT INTO public.actor_series(actorid,seriesid) VALUES (9,17);

INSERT INTO public.actor_series(actorid,seriesid) VALUES (10,12);

19. user
Machine Translated by Google

INSERT INTO public.user(nick,hash_passwd,salt,email,age,countryid,phone_number) VALUES


('Stolarski','ABQUyr625190ienURYTNHGBAqweYIm','ERUIJKNW23','[email protected]',
'1997-12-15',1,'982-756-165');

INSERT INTO public.user(nick,hash_passwd,salt,email,age,countryid,phone_number) VALUES


('Pingwin16','SUTI5678WEHBNEUIP20396821KCTN2','ENB34JKL12','From0Manchester@gmai
l.com','2013-05-06',2,'867-147-173');

INSERT INTO public.user(nick,hash_passwd,salt,email,age,countryid,phone_number) VALUES


('Roboloxo','URH3JFMN54NGU54INGTI45NGI45NG4','WERUTHNU13','[email protected]
m','2015-01-01',3,'209-652-802');

INSERT INTO public.user(nick,hash_passwd,salt,email,age,countryid,phone_number) VALUES


('Khadgar','EIUHG8479GH487UGH4587UH4875HG2','BYWEUVBUW2','K0Porebskipe@gmail.
com','2007-08-12',4,'056-195-320');

INSERT INTO public.user(nick,hash_passwd,salt,email,age,countryid,phone_number) VALUES


('Ragnaros','JG398GJ938WGJH389GHJ983GHJ3894','JG39G39G38','[email protected]','199
8-11-17',5,'175-486-091');

INSERT INTO public.user(nick,hash_passwd,salt,email,age,countryid,phone_number) VALUES


('Anduin','SIDUHFSIDUFHSIFHEW882HF2I8FB28','WEHFBHWBFR','[email protected]','
2005-07-23',6,'450-184-284');

INSERT INTO public.user(nick,hash_passwd,salt,email,age,countryid,phone_number) VALUES


('Jaina1976','UWRHN28GBV823VGBN832GHNIK3INHQ','2R2G3H35J3','[email protected]'
,'1973-04-04',7,'826-687-103');

INSERT INTO public.user(nick,hash_passwd,salt,email,age,countryid,phone_number) VALUES


('Uther2012','EGRFH38RGHV8R7EHG3I8HGF29FJ28J','WFNH82F7NB','JacobsPersonalEmail@
gmail.com','1940-05-08',8,'856-185-327');

INSERT INTO public.user(nick,hash_passwd,salt,email,age,countryid,phone_number) VALUES


('Tyrande56','WIOFJN827HNGVUI3WRNH32874H29GN','GNH2847HG2','LadyHelenpe@gmail.
com','1986-12-12',9,'952-587-175');

INSERT INTO public.user(nick,hash_passwd,salt,email,age,countryid,phone_number) VALUES


('Malfurion23','WOY85IDNSJW64JNM1Y3N1JFN2UGM4K','HJTYU2MFU4','to_jest_moj_email
[email protected]','2006-06-19',10,'732-801-296');

20. serie_productioncountry
Machine Translated by Google

INSERT INTO public.serie_productionCountry(serieid,countryid) VALUES (10,9);

INSERT INTO public.serie_productionCountry(serieid,countryid) VALUES (9,9);

INSERT INTO public.serie_productionCountry(serieid,countryid) VALUES (11,2);

INSERT INTO public.serie_productionCountry(serieid,countryid) VALUES (14,9);

INSERT INTO public.serie_productionCountry(serieid,countryid) VALUES (15,9);

INSERT INTO public.serie_productionCountry(serieid,countryid) VALUES (12,3);

INSERT INTO public.serie_productionCountry(serieid,countryid) VALUES (14,4);

INSERT INTO public.serie_productionCountry(serieid,countryid) VALUES (16,6);

INSERT INTO public.serie_productionCountry(serieid,countryid) VALUES (11,9);

INSERT INTO public.serie_productionCountry(serieid,countryid) VALUES (10,9);

21. device_user

INSERT INTO public.device_user(DeviceId,userId,last_used) VALUES (1,1,'2020-04-26


15:46:57');

INSERT INTO public.device_user(DeviceId,userId,last_used) VALUES (2,4,'2021-05-14


21:03:29');

INSERT INTO public.device_user(DeviceId,userId,last_used) VALUES (3,2,'2021-02-21


18:35:05');

INSERT INTO public.device_user(DeviceId,userId,last_used) VALUES (5,3,'2020-11-08


10:51:18');

INSERT INTO public.device_user(DeviceId,userId,last_used) VALUES (4,5,'2020-08-12


04:41:22');

INSERT INTO public.device_user(DeviceId,userId,last_used) VALUES (8,1,'2021-07-14


15:55:01');
Machine Translated by Google

INSERT INTO public.device_user(DeviceId,userId,last_used) VALUES (7,7,'2020-04-17


07:48:11');

INSERT INTO public.device_user(DeviceId,userId,last_used) VALUES (10,9,'2021-01-26


10:39:24');

INSERT INTO public.device_user(DeviceId,userId,last_used) VALUES (6,5,'2021-02-23


22:16:42');

INSERT INTO public.device_user(DeviceId,userId,last_used) VALUES (9,4,'2020-12-30


05:45:13');

22. credit_card

INSERT INTO public.credit_card(card_number,cvc,expiration_date,owner_name,owner_lastname)


VALUES ('1234123412341234',123,'01/25','Tomek','Kowalski');

INSERT INTO public.credit_card(card_number,cvc,expiration_date,owner_name,owner_lastname)


VALUES('2323232323232323',234,'02/26','Tymon','Doubt');

INSERT INTO public.credit_card(card_number,cvc,expiration_date,owner_name,owner_lastname)


VALUES ('3434343434433443',232,'05/28','Karolina','Tusk');

INSERT INTO public.credit_card(card_number,cvc,expiration_date,owner_name,owner_lastname)


VALUES ('4567456745674678',964,'12/23','Natalia','Gosiewska');

INSERT INTO public.credit_card(card_number,cvc,expiration_date,owner_name,owner_lastname)


VALUES ('5123123412346235',841,'11/24','Monika','Czajka');

INSERT INTO public.credit_card(card_number,cvc,expiration_date,owner_name,owner_lastname)


VALUES ('6511879875164174',102,'08/22','Dominik','Godlewski');

INSERT INTO public.credit_card(card_number,cvc,expiration_date,owner_name,owner_lastname)


VALUES ('7417181181951565',966,'07/23','Dominik','Krawczyk');

INSERT INTO public.credit_card(card_number,cvc,expiration_date,owner_name,owner_lastname)


VALUES ('4984187416354987',852,'12/24','Michaÿ','Kowalczyk');

INSERT INTO public.credit_card(card_number,cvc,expiration_date,owner_name,owner_lastname)


VALUES ('7498498747846579',741,'11/22','Aneta','Stable');

INSERT INTO public.credit_card(card_number,cvc,expiration_date,owner_name,owner_lastname)


VALUES ('7894561237894568',420,'10/23','Michalina','Nowak');

23. film_wanted_to_watch
Machine Translated by Google

INSERT INTO public.film_wanted_to_watch(id_Film_wanted_to_watch) VALUES (1);

INSERT INTO public.film_wanted_to_watch(id_Film_wanted_to_watch) VALUES (2);

INSERT INTO public.film_wanted_to_watch(id_Film_wanted_to_watch) VALUES (3);

INSERT INTO public.film_wanted_to_watch(id_Film_wanted_to_watch) VALUES (4);

INSERT INTO public.film_wanted_to_watch(id_Film_wanted_to_watch) VALUES (5);

INSERT INTO public.film_wanted_to_watch(id_Film_wanted_to_watch) VALUES (6);

INSERT INTO public.film_wanted_to_watch(id_Film_wanted_to_watch) VALUES (7);

INSERT INTO public.film_wanted_to_watch(id_Film_wanted_to_watch) VALUES (8);

INSERT INTO public.film_wanted_to_watch(id_Film_wanted_to_watch) VALUES (9);

INSERT INTO public.film_wanted_to_watch(id_Film_wanted_to_watch) VALUES (10);

24. series_wanted_to_watch

INSERT INTO public.series_wanted_to_watch(id_series_wanted_to_watch) VALUES (1);

INSERT INTO public.series_wanted_to_watch(id_series_wanted_to_watch) VALUES (2);

INSERT INTO public.series_wanted_to_watch(id_series_wanted_to_watch) VALUES (3);

INSERT INTO public.series_wanted_to_watch(id_series_wanted_to_watch) VALUES (4);

INSERT INTO public.series_wanted_to_watch(id_series_wanted_to_watch) VALUES (5);

INSERT INTO public.series_wanted_to_watch(id_series_wanted_to_watch) VALUES (6);

INSERT INTO public.series_wanted_to_watch(id_series_wanted_to_watch) VALUES (7);

INSERT INTO public.series_wanted_to_watch(id_series_wanted_to_watch) VALUES (8);

INSERT INTO public.series_wanted_to_watch(id_series_wanted_to_watch) VALUES (9);


Machine Translated by Google

INSERT INTO public.series_wanted_to_watch(id_series_wanted_to_watch) VALUES (10);

25. payment_method

INSERT INTO public.payment_method(credit_cardid,gift_cardid) VALUES (1,1);

INSERT INTO public.payment_method(credit_cardid,gift_cardid) VALUES (2,NULL);

INSERT INTO public.payment_method(credit_cardid,gift_cardid) VALUES (3,2);

INSERT INTO public.payment_method(credit_cardid,gift_cardid) VALUES (4,NULL);

INSERT INTO public.payment_method(credit_cardid,gift_cardid) VALUES (5,NULL);

INSERT INTO public.payment_method(credit_cardid,gift_cardid) VALUES (6,4);

INSERT INTO public.payment_method(credit_cardid,gift_cardid) VALUES (7,9);

INSERT INTO public.payment_method(credit_cardid,gift_cardid) VALUES (8,NULL);

INSERT INTO public.payment_method(credit_cardid,gift_cardid) VALUES (9,NULL);

INSERT INTO public.payment_method(credit_cardid,gift_cardid) VALUES (10,NULL);

26. payment

INSERT INTO public.payment(payment_date,payment_methodid,payment_plansid) VALUES


('2020-11-12 14:51:23',1,1);

INSERT INTO public.payment(payment_date,payment_methodid,payment_plansid) VALUES


('2021-10-13 17:24:13',2,2);
Machine Translated by Google

INSERT INTO public.payment(payment_date,payment_methodid,payment_plansid) VALUES


('2019-12-21 15:38:56',3,3);

INSERT INTO public.payment(payment_date,payment_methodid,payment_plansid) VALUES


('2021-05-06 07:29:41',4,4);

INSERT INTO public.payment(payment_date,payment_methodid,payment_plansid) VALUES


('2021-04-01 09:24:35',5,5);

INSERT INTO public.payment(payment_date,payment_methodid,payment_plansid) VALUES


('2021-01-01 00:00:00',6,1);

INSERT INTO public.payment(payment_date,payment_methodid,payment_plansid) VALUES


('2020-06-04 22:24:23',7,2);

INSERT INTO public.payment(payment_date,payment_methodid,payment_plansid) VALUES


('2018-05-06 14:23:46',8,3);

INSERT INTO public.payment(payment_date,payment_methodid,payment_plansid) VALUES


('2017-11-16 19:28:10',9,4);

INSERT INTO public.payment(payment_date,payment_methodid,payment_plansid) VALUES


('2020-12-14 13:56:23',10,5);

27. user_profiles

INSERT INTO
public.user_profiles(nickname,profile_photosid,uzytkownikid,is_adult,Languagesid,FIlm_Wanted_t
o_watchid,Series_wanted_to_watchid) VALUES ('Rollermix',1,1,'\000',1,1,NULL);
INSERT INTO
public.user_profiles(nickname,profile_photosid,uzytkownikid,is_adult,Languagesid,FIlm_Wanted_t
o_watchid,Series_wanted_to_watchid) VALUES ('Durszlak',2,2,'\000',2,NULL,NULL);
INSERT INTO
public.user_profiles(nickname,profile_photosid,uzytkownikid,is_adult,Languagesid,FIlm_Wanted_t
o_watchid,Series_wanted_to_watchid) VALUES ('Krokiet',3,3,'\000',3,NULL,1);
Machine Translated by Google

INSERT INTO
public.user_profiles(nickname,profile_photosid,uzytkownikid,is_adult,Languagesid,FIlm_Wanted_t
o_watchid,Series_wanted_to_watchid) VALUES ('Ruen',3,4,'\000',1,NULL,NULL);
INSERT INTO
public.user_profiles(nickname,profile_photosid,uzytkownikid,is_adult,Languagesid,FIlm_Wanted_t
o_watchid,Series_wanted_to_watchid) VALUES ('Elwi',4,5,'\000',1,2,NULL);
INSERT INTO
public.user_profiles(nickname,profile_photosid,uzytkownikid,is_adult,Languagesid,FIlm_Wanted_t
o_watchid,Series_wanted_to_watchid) VALUES ('Vdr1984',5,6,'\000',1,NULL,NULL);
INSERT INTO
public.user_profiles(nickname,profile_photosid,uzytkownikid,is_adult,Languagesid,FIlm_Wanted_t
o_watchid,Series_wanted_to_watchid) VALUES ('Hallack',6,7,'\001',1,NULL,NULL);
INSERT INTO
public.user_profiles(nickname,profile_photosid,uzytkownikid,is_adult,Languagesid,FIlm_Wanted_t
o_watchid,Series_wanted_to_watchid) VALUES ('Multi',8,2,'\001',1,3,NULL);
INSERT INTO
public.user_profiles(nickname,profile_photosid,uzytkownikid,is_adult,Languagesid,FIlm_Wanted_t
o_watchid,Series_wanted_to_watchid) VALUES ('Skillplease',1,2,'\001',1,NULL,NULL);
INSERT INTO
public.user_profiles(nickname,profile_photosid,uzytkownikid,is_adult,Languagesid,FIlm_Wanted_t
o_watchid,Series_wanted_to_watchid) VALUES ('Prysio',2,1,'\001',1,NULL,NULL);

28. profile_is_watching

INSERT INTO public.profile_is_watching(user_profilesid,Episode_serieid,Filmid,date) VALUES


(14,2,NULL,'2020-06-22 11:10:25');

INSERT INTO public.profile_is_watching(user_profilesid,Episode_serieid,Filmid,date) VALUES


(15,NULL,1,'2021-04-23 12:10:25');

INSERT INTO public.profile_is_watching(user_profilesid,Episode_serieid,Filmid,date) VALUES


(16,NULL,NULL,'2020-03-22 13:10:25');

INSERT INTO public.profile_is_watching(user_profilesid,Episode_serieid,Filmid,date) VALUES


(17,NULL,NULL,'2020-05-22 14:10:25');
Machine Translated by Google

INSERT INTO public.profile_is_watching(user_profilesid,Episode_serieid,Filmid,date) VALUES


(18,5,NULL,'2020-02-22 15:10:25');

INSERT INTO public.profile_is_watching(user_profilesid,Episode_serieid,Filmid,date) VALUES


(19,NULL,6,'2021-01-22 16:10:25');

INSERT INTO public.profile_is_watching(user_profilesid,Episode_serieid,Filmid,date) VALUES


(20,7,NULL,'2021-01-22 17:10:25');

INSERT INTO public.profile_is_watching(user_profilesid,Episode_serieid,Filmid,date) VALUES


(21,NULL,8,'2020-01-22 19:10:25');

INSERT INTO public.profile_is_watching(user_profilesid,Episode_serieid,Filmid,date) VALUES


(22,NULL,NULL,'2021-01-22 19:10:25');

INSERT INTO public.profile_is_watching(user_profilesid,Episode_serieid,Filmid,date) VALUES


(23,NULL,NULL,'2021-02-22 12:10:25');

29. watching_history

INSERT INTO public.watching_history(profile_is_watchingid_session,stop_watching_moment)


VALUES (2,34);

INSERT INTO public.watching_history(profile_is_watchingid_session,stop_watching_moment)


VALUES (3,54);

INSERT INTO public.watching_history(profile_is_watchingid_session,stop_watching_moment)


VALUES (4,12);

INSERT INTO public.watching_history(profile_is_watchingid_session,stop_watching_moment)


VALUES (5,15);

INSERT INTO public.watching_history(profile_is_watchingid_session,stop_watching_moment)


VALUES (6,20);

INSERT INTO public.watching_history(profile_is_watchingid_session,stop_watching_moment)


VALUES (7,13);

INSERT INTO public.watching_history(profile_is_watchingid_session,stop_watching_moment)


VALUES (8,14);

INSERT INTO public.watching_history(profile_is_watchingid_session,stop_watching_moment)


VALUES (9,32);

INSERT INTO public.watching_history(profile_is_watchingid_session,stop_watching_moment)


VALUES (10,10);
Machine Translated by Google

INSERT INTO public.watching_history(profile_is_watchingid_session,stop_watching_moment)


VALUES (11,12);

30. serie_series_wanted_to_watch

INSERT INTO public.serie_series_wanted_to_watch(Serieid,Series_wanted_to_watchid) VALUES


(9,1);

INSERT INTO public.serie_series_wanted_to_watch(Serieid,Series_wanted_to_watchid) VALUES


(10,2);

INSERT INTO public.serie_series_wanted_to_watch(Serieid,Series_wanted_to_watchid) VALUES


(11,3);

INSERT INTO public.serie_series_wanted_to_watch(Serieid,Series_wanted_to_watchid) VALUES


(12,4);

INSERT INTO public.serie_series_wanted_to_watch(Serieid,Series_wanted_to_watchid) VALUES


(13,5);

INSERT INTO public.serie_series_wanted_to_watch(Serieid,Series_wanted_to_watchid) VALUES


(14,6);

INSERT INTO public.serie_series_wanted_to_watch(Serieid,Series_wanted_to_watchid) VALUES


(15,7);

INSERT INTO public.serie_series_wanted_to_watch(Serieid,Series_wanted_to_watchid) VALUES


(16,8);

INSERT INTO public.serie_series_wanted_to_watch(Serieid,Series_wanted_to_watchid) VALUES


(14,9);

INSERT INTO public.serie_series_wanted_to_watch(Serieid,Series_wanted_to_watchid) VALUES


(12,10);

31. film_film_wanted_to_watch
Machine Translated by Google

INSERT INTO public.film_Film_wanted_to_watch(Filmid,FIlm_Wanted_to_watchid) VALUES


(1,1);

INSERT INTO public.film_Film_wanted_to_watch(Filmid,FIlm_Wanted_to_watchid) VALUES


(2,2);

INSERT INTO public.film_Film_wanted_to_watch(Filmid,FIlm_Wanted_to_watchid) VALUES


(3,3);

INSERT INTO public.film_Film_wanted_to_watch(Filmid,FIlm_Wanted_to_watchid) VALUES


(4,4);

INSERT INTO public.film_Film_wanted_to_watch(Filmid,FIlm_Wanted_to_watchid) VALUES


(5,5);

INSERT INTO public.film_Film_wanted_to_watch(Filmid,FIlm_Wanted_to_watchid) VALUES


(6,6);

INSERT INTO public.film_Film_wanted_to_watch(Filmid,FIlm_Wanted_to_watchid) VALUES


(7,7);

INSERT INTO public.film_Film_wanted_to_watch(Filmid,FIlm_Wanted_to_watchid) VALUES


(8,8);

INSERT INTO public.film_Film_wanted_to_watch(Filmid,FIlm_Wanted_to_watchid) VALUES


(9,9);

INSERT INTO public.film_Film_wanted_to_watch(Filmid,FIlm_Wanted_to_watchid) VALUES


(10,10);

32. film_country

INSERT INTO public.film_country(genreid,Filmid) VALUES (1,1);

INSERT INTO public.film_country(genreid,Filmid) VALUES (2,2);

INSERT INTO public.film_country(genreid,Filmid) VALUES (3,3);

INSERT INTO public.film_country(genreid,Filmid) VALUES (4,4);

INSERT INTO public.film_country(genreid,Filmid) VALUES (5,5);

INSERT INTO public.film_country(genreid,Filmid) VALUES (6,6);

INSERT INTO public.film_country(genreid,Filmid) VALUES (7,7);


Machine Translated by Google

INSERT INTO public.film_country(genreid,Filmid) VALUES (8,8);

INSERT INTO public.film_country(genreid,Filmid) VALUES (9,9);

INSERT INTO public.film_country(genreid,Filmid) VALUES (10,10);

33. user_payment_method

INSERT INTO public.user_payment_method(Userid,payment_methodid) VALUES (1,1);

INSERT INTO public.user_payment_method(Userid,payment_methodid) VALUES (2,2);

INSERT INTO public.user_payment_method(Userid,payment_methodid) VALUES (3,3);

INSERT INTO public.user_payment_method(Userid,payment_methodid) VALUES (4,4);

INSERT INTO public.user_payment_method(Userid,payment_methodid) VALUES (5,5);

INSERT INTO public.user_payment_method(Userid,payment_methodid) VALUES (6,6);

INSERT INTO public.user_payment_method(Userid,payment_methodid) VALUES (7,7);

INSERT INTO public.user_payment_method(Userid,payment_methodid) VALUES (8,8);

INSERT INTO public.user_payment_method(Userid,payment_methodid) VALUES (9,9);

INSERT INTO public.user_payment_method(Userid,payment_methodid) VALUES (10,10);

You might also like