Exercise 4

Tables (6)

Untitled (CUSTOMER)

  • Key (cusNumber) — char(10) — Primary key — NOT NULL
  • Field (name) — char(10)
  • Field (phone) — char(10)

Untitled (DVD)

  • Key (Code) — char(30) — Primary key — NOT NULL
  • Key (copyCode) — char(30) — Primary key — NOT NULL
  • Field (purchaseDate) — text
  • Field (rentNumber) — text

Untitled (STORE)

  • Key (Code) — char(30) — Foreign key → Untitled.Key — NOT NULL
  • Key (copyCode) — char(30) — Foreign key → Untitled.Key — NOT NULL
  • Key (cusNumber) — char(10) — Foreign key → Untitled.Key — NOT NULL
  • Field (date) — integer
  • Field (time) — integer

Untitled (MOVIE)

  • Key (movieID) — char(50) — Primary key — NOT NULL
  • Key (Code) — char(30) — Foreign key → Untitled.Key — NOT NULL
  • Key (copyCode) — char(30) — Foreign key → Untitled.Key — NOT NULL
  • Field (title) — char(50)
  • Field (madeyear) — text
  • Key (actList) — char(30) — Foreign key → Untitled.Key — NOT NULL
  • Key (dirList) — char(20) — Foreign key → Untitled.Key — NOT NULL

Untitled (ACTOR)

  • Key (actList) — char(30) — Primary key — NOT NULL
  • Field (biography) — text

Untitled (DIRECTOR)

  • Key (dirList) — char(20) — Primary key — NOT NULL
  • Field (biography) — text