fixed issue with dygraphs
attempted to implement sqlobject of mysql queries and csv export, but
column names were not SQL safe. Attempted fixes did not work, so
resorted to running queries via MySQLdb