Infrastructure for database upgrade steps, with two upgrades

The SQL upgrade code introduced here was omitted from the previous
checkin. This checkin introduces a second upgrade step, to add
an optional examName field to quizzes table.