SearchHistory preliminary done but a little problem