Initial commit of survey export.

Exports a dump of survey data from a given program in Excel (2003)
format.  (Note: LibreOffice will read the file, but will take a while to
do it, and will mangle the timestamps.)  The reason for Excel 2003 is
that it's easy to write via templates since it's just XML.  If this
seems like a problem, I can consider modifying it to use a package to
write say XLSX.  CSV isn't really an option since we want to have
multiple tabs, for teach/learn and program/per-class.

Doesn't do the per-class questions yet.
Add per-class and cleanup to survey dump

Add support for per-class questions, and clean up a bunch of things.
Also make the performance a little bit less terrible, hopefully.
A few small fixes to survey export
Rewrite survey dump to use xlwt and be more efficient.

I'm pretty sure this version actually does all the database stuff right!
Famous last words....
Merge pull request #537 from benjaminjkraft/issue383

Dump survey data into spreasheet