From d1339b2122e40976287696799a69ab70e66ee913 Mon Sep 17 00:00:00 2001 From: BB Date: Tue, 24 Oct 2023 08:02:36 +0200 Subject: [PATCH] finishing up --- assets/velemenyek.json | 2 +- lekerdezesek/lekerdezesek.sql | 5 +++++ web/index.html | 8 ++++---- 3 files changed, 10 insertions(+), 5 deletions(-) diff --git a/assets/velemenyek.json b/assets/velemenyek.json index aa56f9f..954c239 100644 --- a/assets/velemenyek.json +++ b/assets/velemenyek.json @@ -1 +1 @@ -[{"date":"2023. 10. 10. 9:11:13"},{"velemeny":"asd","date":"2023. 10. 10. 9:11:55"},{"velemeny":"asd","date":"2023. 10. 10. 9:12:24"}] \ No newline at end of file +[{"date":"2023. 10. 10. 9:11:13"},{"velemeny":"asd","date":"2023. 10. 10. 9:11:55"},{"velemeny":"asd","date":"2023. 10. 10. 9:12:24"},{"velemeny":"bruh","date":"2023. 10. 24. 7:56:49"}] \ No newline at end of file diff --git a/lekerdezesek/lekerdezesek.sql b/lekerdezesek/lekerdezesek.sql index bd6ce75..eea2ca2 100644 --- a/lekerdezesek/lekerdezesek.sql +++ b/lekerdezesek/lekerdezesek.sql @@ -35,3 +35,8 @@ SELECT autok.nev, count(autok.id) AS `mennyiseg` FROM berlesek *** 20. feladat +SELECT + ((berlesek.mennyiseg * autok.ar) + berlesek.biztositas) AS `osszes-bevetel`, + round((berlesek.biztositas / ((berlesek.mennyiseg * autok.ar) + berlesek.biztositas)) * 100) AS `max-biztositas-arany` + FROM berlesek + INNER JOIN autok ON autok.id = berlesek.autoId; diff --git a/web/index.html b/web/index.html index 0210ebf..285514c 100644 --- a/web/index.html +++ b/web/index.html @@ -26,16 +26,16 @@