Limit contextual search to a specific knowledge base

swnewton
Kilo Guru

Is there a way to limit the searchers to just a specific knowledge base instead of all knowledge bases?

1 ACCEPTED SOLUTION

Support provided the answer!  



  1. Determine the encoded query for knowledge base they want to use as the filter. (for example, kb_knowledge_base=ff63da309390120039375562967ffbec)
  2. Navigate to the Contextual Search > Search Contexts module, and select the Search Context you want to modify.
  3. On the Search Context Resource Configuration tab, they need to select the Resource Configuration they want to modify.
  4. On the Search Resource Context Properties tab, select the Resource Context property to modify. It should be a Condition Resource Context Property.
  5. On the Resource Context Property, you fill in the Value field with an encoded query to restrict the knowledge base to the desired knowledge base.

View solution in original post

14 REPLIES 14

edwajs
ServiceNow Employee
ServiceNow Employee

To add a second knowledge base to the filter, change the encoded query to include both knowledge bases.



Instead of:   kb_knowledge_base=a7e8a78bff0221009b20ffffffffff17


Make it:   kb_knowledge_baseINa7e8a78bff0221009b20ffffffffff17,ffcdf061ff2121009b20ffffffffffa4


Sweet...so it basically making a SQL query??


edwajs
ServiceNow Employee
ServiceNow Employee

Yes, the encoded query acts as a SQL query filter.


So here's the BIG Question... is there any way to make a subscription-like function so that;

  • If a user has permissions to SEE 5 Knowledge Bases,
  • But does their normal daily job in 2 Knowledge Bases,

Can they select a "default" set to use normally, but then add/remove ones they have permissions to to work on special projects?

That would be USEFUL to users in environments with multiple Knowledge Bases that need dynamic control over what they're searching against.

The function would apply in all search areas - Contextual Search, Knowledge Home Page, Global Search (where KBs are allowed), etc.

satishguru
Tera Contributor

hi



In cal module i have a short description field as a conteaxt search . when i type some thing for example "falsk" inappropiate results are coming. not the exact result.can any one help me on this