Various updates in preparation for correcting sort order issues