From 06e9357597840d045939b7927288461763e89af9 Mon Sep 17 00:00:00 2001 From: Jake Lawhorne Date: Sun, 26 Mar 2023 14:56:47 -0400 Subject: [PATCH 1/6] exercise1 complete --- .idea/.gitignore | 3 + .idea/SQL.LetsGetTogether.iml | 9 + .idea/dbnavigator.xml | 417 ++++++++++++++++++++++++++++++++++ .idea/misc.xml | 6 + .idea/modules.xml | 8 + .idea/vcs.xml | 6 + answers/exercise1.sql | 4 + 7 files changed, 453 insertions(+) create mode 100644 .idea/.gitignore create mode 100644 .idea/SQL.LetsGetTogether.iml create mode 100644 .idea/dbnavigator.xml create mode 100644 .idea/misc.xml create mode 100644 .idea/modules.xml create mode 100644 .idea/vcs.xml diff --git a/.idea/.gitignore b/.idea/.gitignore new file mode 100644 index 0000000..26d3352 --- /dev/null +++ b/.idea/.gitignore @@ -0,0 +1,3 @@ +# Default ignored files +/shelf/ +/workspace.xml diff --git a/.idea/SQL.LetsGetTogether.iml b/.idea/SQL.LetsGetTogether.iml new file mode 100644 index 0000000..d6ebd48 --- /dev/null +++ b/.idea/SQL.LetsGetTogether.iml @@ -0,0 +1,9 @@ + + + + + + + + + \ No newline at end of file diff --git a/.idea/dbnavigator.xml b/.idea/dbnavigator.xml new file mode 100644 index 0000000..fa4c6be --- /dev/null +++ b/.idea/dbnavigator.xml @@ -0,0 +1,417 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/misc.xml b/.idea/misc.xml new file mode 100644 index 0000000..639900d --- /dev/null +++ b/.idea/misc.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/.idea/modules.xml b/.idea/modules.xml new file mode 100644 index 0000000..a731dc1 --- /dev/null +++ b/.idea/modules.xml @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 0000000..35eb1dd --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/answers/exercise1.sql b/answers/exercise1.sql index e69de29..3923a6d 100644 --- a/answers/exercise1.sql +++ b/answers/exercise1.sql @@ -0,0 +1,4 @@ +SELECT * +FROM Enrolments e +LEFT JOIN Students s +ON e.Student_ID = s.Student_ID; \ No newline at end of file From 8b3c39bbddabc783bd60fc2195d004213d94d2f4 Mon Sep 17 00:00:00 2001 From: Jake Lawhorne Date: Sun, 26 Mar 2023 15:20:21 -0400 Subject: [PATCH 2/6] exercise 2 completed --- answers/exercise2.sql | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/answers/exercise2.sql b/answers/exercise2.sql index e69de29..8eded48 100644 --- a/answers/exercise2.sql +++ b/answers/exercise2.sql @@ -0,0 +1,4 @@ +SELECT * +FROM Enrolments e +JOIN Students s +ON e.Student_ID = s.Student_ID; \ No newline at end of file From 8dd7e2373919fb044d83db7ba03e492875c56096 Mon Sep 17 00:00:00 2001 From: Jake Lawhorne Date: Sun, 26 Mar 2023 15:31:38 -0400 Subject: [PATCH 3/6] exercise3 complete --- answers/exercise3.sql | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/answers/exercise3.sql b/answers/exercise3.sql index e69de29..18257a3 100644 --- a/answers/exercise3.sql +++ b/answers/exercise3.sql @@ -0,0 +1,4 @@ +SELECT * +FROM Enrolments e +RIGHT JOIN students s +ON e.Student_ID = s.Student_ID; \ No newline at end of file From 6252ceca51378e7fd233eb28776bd2b0cf75a0bd Mon Sep 17 00:00:00 2001 From: Jake Lawhorne Date: Sun, 26 Mar 2023 15:38:10 -0400 Subject: [PATCH 4/6] exercise4 complete --- answers/exercise4.sql | 3 +++ 1 file changed, 3 insertions(+) diff --git a/answers/exercise4.sql b/answers/exercise4.sql index e69de29..e343263 100644 --- a/answers/exercise4.sql +++ b/answers/exercise4.sql @@ -0,0 +1,3 @@ +SELECT Country, COUNT(*) +FROM Students +GROUP BY Country; From 06135e61e8d367c4d4b3b09e907b271bf15c59e6 Mon Sep 17 00:00:00 2001 From: Jake Lawhorne Date: Sun, 26 Mar 2023 15:41:18 -0400 Subject: [PATCH 5/6] exercise5 complete --- answers/exercise5.sql | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/answers/exercise5.sql b/answers/exercise5.sql index e69de29..cfa603f 100644 --- a/answers/exercise5.sql +++ b/answers/exercise5.sql @@ -0,0 +1,4 @@ +SELECT Country, COUNT(*) +FROM Students +GROUP BY Country +ORDER BY COUNT(*); \ No newline at end of file From eb6adc432ff80580746dee52c6b956983c07f00d Mon Sep 17 00:00:00 2001 From: Jake Lawhorne Date: Sun, 26 Mar 2023 15:44:37 -0400 Subject: [PATCH 6/6] exercise 6 completed --- answers/exercise6.sql | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/answers/exercise6.sql b/answers/exercise6.sql index e69de29..743544f 100644 --- a/answers/exercise6.sql +++ b/answers/exercise6.sql @@ -0,0 +1,5 @@ +SELECT Country, COUNT(*) +FROM Students +GROUP BY Country +ORDER BY COUNT(*) +HAVING COUNT(*) > 10; \ No newline at end of file