The document contains SQL code to create multiple database tables - Platform, Games, Country, Developer, GameDeveloper, Genre, and GameGenre. These tables contain fields to store information about video game platforms, individual games, the countries and developers associated with games, and the genres of games. Data is inserted into the tables as examples.
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as RTF, PDF, TXT or read online on Scribd
0 ratings0% found this document useful (0 votes)
21 views2 pages
Games
The document contains SQL code to create multiple database tables - Platform, Games, Country, Developer, GameDeveloper, Genre, and GameGenre. These tables contain fields to store information about video game platforms, individual games, the countries and developers associated with games, and the genres of games. Data is inserted into the tables as examples.
gameName varchar(50), gameId int NOT NULL AUTO_INCREMENT, gamePrice double, gameRank double, gameBudget int, platformId int, PRIMARY KEY (gameId), FOREIGN KEY (platformId) REFERENCES Platform(platformId) ); INSERT INTO Games(gameName, gamePrice, gameRank, gameBudget, platformId) VALUES ('Minecraft',249.99,3.3,10000000,2), ('Call of Duty: Black Ops',199.99,4.5,18000000,1), ('Grand Theft Auto V',179.59,4.6,265000000,3), ('Need For Speed',350.99,3.9,66000000,1), ('The Legend of Zelda: Link''s Awakening',109.99,4.2,4000000,5);
CREATE TABLE Country(
countryId int NOT NULL AUTO_INCREMENT, countyName varchar(50), PRIMARY KEY(countryId) ); INSERT INTO Country (countyName) VALUES ('Sweden'), ('USA'), ('England'), ('Japan');