From 12199d5f12a2ae06cdf2bb679b95a43de85e03ce Mon Sep 17 00:00:00 2001 From: Felix Albrigtsen Date: Tue, 29 Mar 2022 20:08:31 +0200 Subject: [PATCH] Team linking --- src/server/management/initDB.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/server/management/initDB.sql b/src/server/management/initDB.sql index a858525..216c308 100644 --- a/src/server/management/initDB.sql +++ b/src/server/management/initDB.sql @@ -43,7 +43,7 @@ CREATE TABLE players ( name TEXT NOT NULL, teamId INTEGER NOT NULL, - FOREIGN KEY (teamId) REFERENCES teams (id) + FOREIGN KEY (teamId) REFERENCES teams (id) ON DELETE CASCADE ); -- Example data (Two tournaments, 4 teams, single elimination)