Fixed error in creating a report