Skip to content
Browse files

Schema for tags and Games

  • Loading branch information...
1 parent d25254a commit cb7d420cd0bb3e2c7523d2021f3c38ee8b5576a0 @kthakore kthakore committed Dec 22, 2010
Showing with 17 additions and 0 deletions.
  1. +17 −0 schema.sql
View
17 schema.sql
@@ -0,0 +1,17 @@
+CREATE TABLE Game (
+ ID INTEGER PRIMARY KEY,
+ name TEXT,
+ info TEXT,
+ image TEXT
+ );
+
+CREATE TABLE Tag (
+ ID INTEGER PRIMARY KEY,
+ name TEXT
+ );
+
+CREATE TABLE GamesTag(
+ ID INT NOT NULL UNIQUE PRIMARY KEY,
+ gameID INT NOT NULL CONSTRAINT fk_games_id REFERENCES Game(ID),
+ tagID INT NOT NULL CONSTRAINT fk_tag_id REFERENCES Tag(ID)
+ );

0 comments on commit cb7d420

Please sign in to comment.
Something went wrong with that request. Please try again.