Added sorting of result list by ID