Commit 39acd080 authored by Nico Schallehn's avatar Nico Schallehn

DB umstellung

parent 713156c9
......@@ -284,7 +284,7 @@ class MediaDBViewerAPI{
}
if ($Statistik == true) {
if (($GET_arr['Tabelle'] == "Staffeln")) {
$Query = 'SELECT avg(e.checked) AS Checked, avg(s.views) AS Views, SUM(e.size) AS Size '.
$Query = 'SELECT avg(e.checked) AS Checked, avg(e.views) AS Views, SUM(e.size) AS Size '.
'FROM Staffeln AS s JOIN Episoden AS e ON s.season_nr = e.season_nr '.
'WHERE s.season_nr = '.$entry["season_nr"];
$result = $this->query($Query);
......@@ -295,7 +295,7 @@ class MediaDBViewerAPI{
$tempArray["Size"] = $resultArr["Size"];
}else if (($GET_arr['Tabelle'] == "Serien")){
$Query = 'SELECT avg(e.checked) AS Checked, avg(st.views) AS Views, SUM(e.size) AS Size '.
$Query = 'SELECT avg(e.checked) AS Checked, avg(e.views) AS Views, SUM(e.size) AS Size '.
'FROM Serien AS se JOIN Staffeln AS st ON se.series_nr=st.series_nr JOIN Episoden AS e ON st.season_nr = e.season_nr '.
'WHERE se.series_nr = '.$entry["series_nr"];
$result = $this->query($Query);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment