Version 5 (modified by 8 hours ago) ( diff ) | ,
---|
Релации:
Track
- track_id (PK)
- name (NOT NULL)
- album_id* (FK → Album)
- media_type_id* (FK → MediaType)
- genre_id* (FK → Genre)
- composer
- milliseconds (NOT NULL)
- bytes (NOT NULL)
Album
- album_id (PK)
- title (NOT NULL)
- artist_id* (FK → Artist)
Artist
- artist_id (PK)
- name (NOT NULL)
Genre
- genre_id (PK)
- name (NOT NULL)
MediaType
- media_type_id (PK)
- name (NOT NULL)
Price
- price_id (PK)
- value (NOT NULL)
- date (NOT NULL)
- track_id* (FK → Track)
InvoiceLine
- invoice_line_id (PK)
- invoice_id* (FK → Invoice)
- track_id* (FK → Track)
- quantity (NOT NULL)
Invoice
- invoice_id (PK)
- customer_id* (FK → Customer)
- invoice_date (NOT NULL)
- billing_address
- billing_city
- billing_state
- billing_country
- billing_postal_code
- total (NOT NULL)
Customer
- customer_id (PK)
- first_name (NOT NULL)
- last_name (NOT NULL)
- company
- support_rep_id* (FK → Employee)
- personal_info_id* (FK → AddressInfo)
- contact_id* (FK → Contact)
Employee
- employee_id (PK)
- first_name (NOT NULL)
- last_name (NOT NULL)
- title (NOT NULL)
- reports_to* (FK → Employee)
- birth_date (NOT NULL)
- hire_date (NOT NULL)
- personal_info_id* (FK → AddressInfo)
- contact_id* (FK → Contact)
AddressInfo
- address_info_id (PK)
- address (NOT NULL)
- city (NOT NULL)
- state
- country (NOT NULL)
- postal_code (NOT NULL)
Contact
- contact_id (PK)
- phone (NOT NULL)
- fax
- email (NOT NULL)
Playlist
- playlist_id (PK)
- name (NOT NULL)
PlaylistTrack
- playlist_track_id (PK)
- playlist_id* (FK → Playlist)
- track_id* (FK → Track)
Attachments (4)
- primary_ddl.sql (2.8 KB ) - added by 8 hours ago.
- dml_insertions_1.sql (202.0 KB ) - added by 8 hours ago.
- dml_insretions_2.sql (249.6 KB ) - added by 8 hours ago.
- dml_insertion_3.sql (142.8 KB ) - added by 8 hours ago.
Download all attachments as: .zip
Note:
See TracWiki
for help on using the wiki.