34 lines
594 B
Plaintext
34 lines
594 B
Plaintext
|
SELECT Region, COUNT(ALL NumVin)
|
||
|
FROM Vin
|
||
|
GROUP BY Region;
|
||
|
|
||
|
|
||
|
SELECT NUMVITIC, NOM, COUNT(ALL CRU)
|
||
|
FROM VITICULTEUR NATURAL JOIN VIN
|
||
|
GROUP BY NUMVITIC, NOM
|
||
|
|
||
|
|
||
|
SELECT NOM, NUMBUVEUR,AVG(ALL QTTE)
|
||
|
FROM BUVEUR NATURAL JOIN COMMANDE
|
||
|
WHERE VILLE='PARIS'
|
||
|
GROUP BY NOM, NUMBUVEUR;
|
||
|
|
||
|
|
||
|
SELECT NOM, COUNT(*)
|
||
|
FROM BUVEUR NATURAL JOIN COMMANDE
|
||
|
GROUP BY NOM;
|
||
|
|
||
|
|
||
|
SELECT NOM, SUM(ALL QTTE)
|
||
|
FROM BUVEUR NATURAL JOIN COMMANDE
|
||
|
GROUP BY NOM
|
||
|
HAVING AVG(ALL QTTE) >= 12;
|
||
|
|
||
|
|
||
|
SELECT NOM, NUMVITIC
|
||
|
FROM VITICULTEUR NATURAL JOIN VIN
|
||
|
GROUP BY NOM, NUMVITIC
|
||
|
HAVING COUNT(DISTINCT CRU) >= 2;
|
||
|
|
||
|
|