Added logic for getting report infos from database