Updated component to be more verbose about errors encountered during database queries