Search Returns Catalog Results (Before Knowledge)

Raj64
Tera Guru

Hello everyone,

 

Whenever my Fallback Search topic is executed, it always displays results from the catalog first instead of knowledge bases. How do I change the order to display knowledge articles first?

2 REPLIES 2

Gunjan Kiratkar
Kilo Patron
Kilo Patron

Hi @Raj64 ,

You can make below changes 

GunjanKiratkar_0-1668621760431.png

Setting the property Interleave Results = false will present the search results in order of relevancy but grouped by search resource eg. knowledge articles appearing first and then catalog items.

 

reference:-

https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0749166 

 

If that field is readonly then run below code in background script :-

Write down proper encoded query

var gr=new GlideRecord("cxs_searcher_config");
gr.addEncodedQuery("active=true^name=Knowledge and catalog");
gr.query();
if(gr.next()){

gr.interleave='false';
gr.update();
}

Please Mark My Response as Correct/Helpful based on Impact
Regards,
Gunjan Kiratkar
2X ServiceNow MVP
Community Rising Star 2022
Youtube : ServiceNow Guy

Raj64
Tera Guru

Hi Gunjan,

 

Interleave is already false (unchecked).