Error handling when connecting to DB
Added map to create report