Join us this Friday for AI in Action at the Virtual Happy Hour! This free virtual event is open to all—enroll now on Academy and don’t miss out.
Join us this Friday for AI in Action at the Virtual Happy Hour! This free virtual event is open to all—enroll now on Academy and don’t miss out.
Hi,
It looks like the page size == 100, is used as a constant and there is no elegant way to change it.
Maybe you could try to use a trick (I didn't test it):
// change the implementation of SearchHandler public class ExtendedSearchHandler: SearchHandler { public override SearchResults GetSearchResults(IQueryExpression queryExpression, string namedIndexingService, Collection<string> namedIndexes, int page, int pageSize) { pageSize = 10000; return base.GetSearchResults(queryExpression, namedIndexingService, namedIndexes, page, pageSize); } } // // use your code below // // replace the instance of searchHandler SearchHandler.Instance = new ExtendedSearchHandler(); UnifiedSearchHitCollection searchresult = new UnifiedSearchHitCollection(); searchresult.Capacity = 999; query.FreeTextQuery = txtSearchValue; searchresult = dir.Search(query);
I have a UnifiedDirectory with 4500+ files in it. When I perform a search using a UnifiedSearchQuery, the UnifiedSearchHitCollection capacity gets reset to 128 and the count returns 100 during the query - for pretty much every query. There's no way the search returns exactly 100 results for most of the criteria. How do I override this behaviour and get all ranked files? There is zero help in the SDK.
Thanks in advance.