Fix issue in my assessments data retrieval query