Added commands to generate reports from database and base command class

encoding should be configurable using command arguments