Q.1-Create this two tables:-
Table name:-Distribution_companies
- id – The ID of the distribution company. This is the primary key,auto increment and not null values of the table.
- company_name – The name of the distribution company.
Id | Company Name |
---|---|
1 | Columbia Pictures |
2 | Paramount Pictures |
3 | Warner Bros. Pictures |
4 | United Artists |
5 | Universal Pictures |
6 | New Line Cinema |
7 | Miramax Films |
8 | Produzioni Europee Associate |
9 | Buena Vista |
10 | StudioCanal |
Table name:-Movies
- id – The ID of the movie. This is the primary key,auto increment,unsigned and not null values of the table.
- movie_title – The movie title.
- imdb_rating – The movie rating on IMDb.
- year_released – The year the movie was released.
- budget – The budget for the movie in millions of dollars.
- box_office – The earnings of the movie in millions of dollars.
- distribution_company_id – The ID of the distribution company, referencing the table distribution_companies (foreign key).
- language – The language(s) spoken in the movie which is by default English
Id | movie_title | imdb_rating | year_released | budget | box_office | distribution_company_id | language |
---|---|---|---|---|---|---|---|
1 | The Shawchank Redemption | 9.20 | 1994 | 25.00 | 73.30 | 1 | English |
2 | The Godfather | 9.20 | 1972 | 7.20 | 291.00 | 2 | English |
3 | The Dark Knight | 9.00 | 2008 | 185.00 | 1000.00 | 3 | English |
4 | The Godfather Part II | 9.00 | 1974 | 13.00 | 93.00 | 2 | English,Spanish |
5 | 12 Angry Men | 9.00 | 1997 | 0.34 | 2.00 | 4 | English |
6 | Sachindler's List | 8.90 | 1993 | 22.00 | 322.20 | 5 | English,German,Spanish |
7 | The Land of Rings | 8.90 | 2003 | 94.00 | 1140.00 | 6 | English |
8 | Pulp Fiction | 8.80 | 1994 | 8.50 | 213.90 | 7 | English |
9 | The Land of Rings | 8.80 | 2001 | 93.00 | 898.20 | 6 | English |
10 | The Good Bad and ugly | 8.80 | 1990 | 1.20 | 38.90 | 8 | English,Italian,Spanish |