From 52cd5756d8f98a87f8800eb51175403d93068bb7 Mon Sep 17 00:00:00 2001 From: Jason Streifling Date: Thu, 19 Oct 2023 20:06:28 +0200 Subject: [PATCH] Kleine Fehlerkorrekturen --- create_tables.sql | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/create_tables.sql b/create_tables.sql index 353f10c..aa6df3b 100644 --- a/create_tables.sql +++ b/create_tables.sql @@ -1,9 +1,12 @@ USE sicherheitsunterweisung; + +SET FOREIGN_KEY_CHECKS = 0; DROP TABLE IF EXISTS instructors; DROP TABLE IF EXISTS briefings; DROP TABLE IF EXISTS participants; DROP TABLE IF EXISTS questions; DROP TABLE IF EXISTS given_answers; +SET FOREIGN_KEY_CHECKS = 1; CREATE TABLE instructors ( id INT NOT NULL AUTO_INCREMENT, @@ -68,7 +71,7 @@ VALUES ( 'Georg', 'aus dem Jungel', '123458' ); INSERT INTO briefings ( - date, time, location, as_of, instructor_id + date, time, location, document_name, as_of, instructor_id ) VALUES ( '2023-10-16', '17:00:00', 'Werk Langenhagen', 'ICS-2021-LGH', '2021-02-01', '1' ), ( '2023-10-16', '17:05:00', 'Werk Langenhagen', 'ICS-2021-LGH', '2021-02-01', '2' ); @@ -84,7 +87,8 @@ INSERT INTO questions ( ) VALUES ( 'Was ist 1+1?', '1', '2', '3', '4', '2' ), ( 'Was ist 1+2?', '1', '2', '3', '4', '3' ), - ( 'Was ist 2+2?', '1', '2', '3', '4', '4' ); + ( 'Was ist 2+2?', '1', '2', '3', '4', '4' ), + ( 'Was ist 0+1?', '1', '2', '3', '4', '1' ); INSERT INTO given_answers ( briefing_id, participant_id, question_id, given_answer @@ -92,6 +96,8 @@ INSERT INTO given_answers ( ( '1', '1', '1', '2' ), ( '1', '1', '2', '3' ), ( '1', '1', '3', '3' ), + ( '1', '1', '4', '1' ), ( '2', '2', '1', '2' ), ( '2', '2', '2', '3' ), - ( '2', '2', '3', '4' ); + ( '2', '2', '3', '4' ), + ( '2', '2', '4', '1' );