[UPGRADELIST]
Description=Remove old zero scoring awards (e.g. team player award for cod4)
UpgradeType=Database Contents
1=$$LOOP row as award index as awardindex select awardpoints.awardindex as idx,max(score) as maxscore,min(score) as minscore,name from awardpoints,awarddefinition where awardpoints.awardindex=awarddefinition.awardindex group by awardpoints.awardindex$$
2=	$$IF (award.minscore EQUALS "0")$$
3=		$$IF (award.maxscore EQUALS "0")$$
4=			// This award has no points
5=			$$updatestatus("Clearing points for award %%award.name%%")$$
6=			$$sql("delete from awardpoints where awardindex=%%award.idx%%")$$
7=		$$ENDIF$$
8=	$$ENDIF$$
9=$$ENDLOOP$$
