update search and sort