How to filter knowledge bases in "Knowledge article template selector" in Agent workspace ?

simpleQubs
Tera Contributor

Hello,

 

I’m having trouble filtering the Knowledge Base list in the Knowledge Article Template Selector within the child table of kb_knowledge in Workspace. I want to display only specific, relevant knowledge bases based on the selected child table.

At the moment, all knowledge bases are being shown regardless of the table.

 

 

simpleQubs_0-1776611239725.png

Please help me to filter knowledge base, based on the table.

4 REPLIES 4

Tanushree Maiti
Kilo Patron

Hi @simpleQubs 

 

Check this : 

Knowledge article template selector Configuration

How to add additional knowledge bases to HR Agent Workspace

 

Please mark this response as Helpful & Accept it as solution if it assisted you with your question.
Regards
Tanushree Maiti
ServiceNow Technical Architect
Linkedin:

Naveen20
ServiceNow Employee

 "Create article" dialog in Workspace pulls from kb_knowledge_base records, and the key to filtering is the Table field on each Knowledge Base record.

Step 1 — Set the Table field on each Knowledge Base

Navigate to Knowledge > Knowledge Bases (kb_knowledge_base.list). Open each knowledge base record and set the Table field to the specific child table of kb_knowledge that it should be associated with (e.g., your custom child table like u_my_kb_article). If a KB should only appear when creating articles on a particular child table, this field must be populated with that table name.

Step 2 — Verify the Reference Qualifier on the dialog

If setting the Table field alone doesn't resolve the filtering in Workspace, you may need to add or adjust the reference qualifier on the Knowledge base field in the dialog. The OOTB qualifier should ideally respect the table column, but if it doesn't, you can add a reference qualifier like:

table=javascript:current.getTableName()^ORtableISEMPTY

This ensures only KBs mapped to the current child table (or KBs with no table restriction) appear in the dropdown.

Step 3 — Workspace-specific configuration

In Workspace (Next Experience), this dialog is typically driven by a Declarative Action. To modify the reference qualifier:

  1. Go to sys_declarative_action_assignment.list and search for the action related to "Create article" or "Knowledge article creation."
  2. Trace it to the associated form or modal configuration.
  3. Apply the reference qualifier on the Knowledge Base field at that level.

Alternatively, if the dialog is rendered through a UI Action or Record Producer, look for the script or variable definition controlling the Knowledge Base field and update the reference qualifier there.

Important note: Make sure the table field on kb_knowledge_base is set to the child table name (not kb_knowledge itself) for each KB you want filtered. KBs with the Table field left empty will typically appear for all tables.

Hello @Naveen20 ,

thanks for the response,

I have tried all suggested steps, but it didn't work out.

 

 

Naveen20
ServiceNow Employee

@simpleQubs You can directly modify the sys_ux_macroponent table record with b53fcaf4dd5f1010f8775c733bdb408a
Check the typeahead_knowledge_base element and it has an inline script and you can filter out records as needed.