error handling in report