diff --git a/mylar/helpers.py b/mylar/helpers.py index cc9fdb85..c329e4dc 100755 --- a/mylar/helpers.py +++ b/mylar/helpers.py @@ -1289,7 +1289,7 @@ def havetotals(refreshit=None): comiclist = myDB.select('SELECT * FROM comics GROUP BY ComicID order by ComicSortName COLLATE NOCASE') else: comiclist = [] - comicref = myDB.selectone('SELECT comics.ComicID, comics.Have, comics.Total, COUNT(totalAnnuals.IssueID) AS TotalAnnuals FROM comics LEFT JOIN annuals as totalAnnuals on totalAnnuals.ComicID = comics.ComicID WHERE comics.ComicID=? GROUP BY comics.ComicID', [refreshit]).fetchone() + comicref = myDB.selectone('SELECT comics.ComicID AS ComicID, comics.Have AS Have, comics.Total as Total, COUNT(totalAnnuals.IssueID) AS TotalAnnuals FROM comics LEFT JOIN annuals as totalAnnuals on totalAnnuals.ComicID = comics.ComicID WHERE comics.ComicID=? GROUP BY comics.ComicID', [refreshit]).fetchone() #refreshit is the ComicID passed from the Refresh Series to force/check numerical have totals comiclist.append({"ComicID": comicref['ComicID'], "Have": comicref['Have'],