Filter smart search results

Francisco Caicedo asked on March 23, 2016 06:01

Hi,

I have the following tree node structure in the CMS:

Parent category 1
    - sub category 1
    - sub category 2


Parent category 2
    - sub category 1
    - sub category 4

Assigned to these nodes there are some pages and linked pages that map to an SKU. I have been trying to remove the duplicate pages by using the following lucene query "-NodeLinkedNodeID:[0 TO 999999999]". This works fine for some scenarios but not for all of them. Let's say I am in the parent category 1 and there are linked pages from parent category 2 then, the linked pages won't show.

Is there a way I can remove the duplicate pages from the parent categories without hiding all the linked pages? Help would be much appreciated.

Thank you,

Francisco

Recent Answers


Roman Hutnyk answered on March 23, 2016 13:34

Francisco, so it sounds like you need to filter out linked documents only when it's original is already present in results set, it this correct?

0 votesVote for this answer Mark as a Correct answer

Roman Hutnyk answered on March 23, 2016 21:59

By default original and linked pages are two different pages, so I'm not sure you can configure Kentico to exclude it. The only possible way I can think of is building custom search results web part. Here is an example of how you could get all search results, so you'll need to implement some logic in order to filter out 'duplicates'.

2 votesVote for this answer Mark as a Correct answer

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