MDL-22139 backup - minor fix to query (grade_item->id is in backup_ids_temp->itemid)