Added Aufgabe 4.6

This commit is contained in:
Leon Amtmann 2022-05-18 11:04:26 +02:00
parent 7ecf4b944d
commit bb84027ccf
2 changed files with 404 additions and 0 deletions

View File

@ -88,3 +88,9 @@ Geben Sie eine SQL Anfrage an, die alle Produkte ausgibt, die eine bestimmte Anz
d. Mehr
-----------------------------------------------------------------------
*/
SELECT Produktname, GROUP_CONCAT(eZ.Anwendungsgrund), GROUP_CONCAT(E_Nummer),
LENGTH(GROUP_CONCAT(E_Nummer)) - LENGTH(REPLACE(GROUP_CONCAT(E_Nummer), ',', '')) + 1 AS 'Anzahl Zusatzstoffe'
FROM Produkt
JOIN enthaeltZusatzstoff eZ on Produkt.ProduktID = eZ.ProduktID
GROUP BY Produktname

398
dump.sql Normal file

File diff suppressed because one or more lines are too long