Search Index Indexed documents

John Fu asked on September 18, 2015 10:15

Is there a way to return all indexed documents in a search index? I've indexed all documents under /Publications/%. And on our publications page, we want to initially load the first 10 documents.

I am currently doing it by using DocumentHelper.GetDocuments(), and it's proving very slow because there are 960 documents underneath Publications.

I can only get the number of indexed documents with SearchIndexInfo.NumberOfIndexedItems, but don't know how to get the actual documents.

SearchHelper.Search(searchParameters) is always returning null when I put in an empty string in the searchfor parameter.

Correct Answer

Maarten van den Hooven answered on September 18, 2015 11:16

You are on the right track with SearchHelper.Search(searchParameters), but maybe there is something going wrong there. Look for example to this forum post.

Here also more information about the Smart search API

Here you can find an code example :-)

If you have no luck, can you then post your code here and we can see what is going wrong or what is missing.

If this answer helped you, please vote for my answer :-)

0 votesVote for this answer Unmark Correct answer

Recent Answers

Tom Troughton answered on May 17, 2016 13:59 (last edited on May 17, 2016 14:16)

Hi John, did you ever find a solution for this? I'm facing the exact same challenge. I've been through the links in the approved answer but none seem to demonstrate how to return all documents.

0 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.