Compare commits
No commits in common. "b10454ead74c8e8009d116397e2d7a040699af94" and "a397fd10168817e7153c25aac25f53f7a7c4a3f1" have entirely different histories.
b10454ead7
...
a397fd1016
1 changed files with 4 additions and 4 deletions
|
|
@ -3,11 +3,11 @@
|
|||
-- --------+---+---+---+---+---+---+---+---+---+----+----+----+----+----+----+----+----+----+----+----+----+
|
||||
-- Axel | | | O | O | | | | | | | | O | O | | | | | | | 0 | |
|
||||
-- --------+---+---+---+---+---+---+---+---+---+----+----+----+----+----+----+----+----+----+----+----+----+
|
||||
-- Ronan | | O | | | | O | | | | O | | | | | | x | | O | | | |
|
||||
-- Ronan | | O | | | | O | | | | O | | | | | | x | | | | | |
|
||||
-- --------+---+---+---+---+---+---+---+---+---+----+----+----+----+----+----+----+----+----+----+----+----+
|
||||
-- Yasmine | | | | | O | | | O | | | | | | O | O | | | | O | | O |
|
||||
-- --------+---+---+---+---+---+---+---+---+---+----+----+----+----+----+----+----+----+----+----+----+----+
|
||||
-- Nathan | O | | | | | | O | | O | | O | | | | | | O | | | | |
|
||||
-- Nathan | O | | | | | | O | | O | | O | | | | | | O | O | | | |
|
||||
-- --------+---+---+---+---+---+---+---+---+---+----+----+----+----+----+----+----+----+----+----+----+----+
|
||||
-- ^ ^ ^
|
||||
-- | | |
|
||||
|
|
@ -181,14 +181,14 @@ WHERE idScientifique IN (
|
|||
WHERE nbProjets = 1
|
||||
);
|
||||
|
||||
-- Ronan QUESTION 18 tested
|
||||
-- Nathan QUESTION 18 (celle de Ronan) tested
|
||||
SELECT * from Scientifique
|
||||
WHERE idScientifique IN (
|
||||
SELECT idScientifique FROM (
|
||||
SELECT idScientifique, COUNT(DISTINCT idProjet) AS nbProjets FROM Participe
|
||||
GROUP BY idScientifique
|
||||
) AS ParticipationCount
|
||||
JOIN (
|
||||
RIGHT JOIN (
|
||||
SELECT COUNT(DISTINCT idProjet) AS nbTotalProjets FROM Projet
|
||||
) AS ProjectCount
|
||||
ON ParticipationCount.nbProjets = ProjectCount.nbTotalProjets
|
||||
|
|
|
|||
Loading…
Reference in a new issue