How to display "When an incident has a knowledge article attached the Knowledge articles "Incident" tab should reflect/populate the incident # that was attached to said article.

Ram141
Tera Expert

When an incident has a knowledge article attached the Knowledge articles "Incident" tab should reflect/populate the incident # that was attached to said article. 

22 REPLIES 22

Similarly we have to add incident tab on Knowledge Article form.

Whenever user attach the knowledge article on incident at the same time on knowledge Article form incident should get updated in the related link tab.

Hi,

Okay so which field on knowlege record stores incident number? can you check that

Regards
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Actually i don't see any field where it is storing incident number.

I have used "Attach Knowledge" gear box to see the values stored in fields.

 

Do i need to check in any other way?

Hi,

there is source field on knowledge table which stores the incident number once knowledge is created from incident

So you can use this for creating relationship

Steps:

1) type relationships in left nav and click on the module under System Definition

2) create new record

3) Applies to Table: kb_knowledge

4) Applies from Table: incident

5) Script below

(function refineQuery(current, parent) {

	// Add your code here, such as current.addQuery(field, value);

	current.addQuery('sys_id', parent.source);
	
})(current, parent);

Then add this related list on form by configuring related lists; search and move it from left to right

find_real_file.png

find_real_file.png

find_real_file.png

Output:

find_real_file.png

Mark Correct if this solves your issue and also mark 👍 Helpful if you find my response worthy based on the impact.
Thanks
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

But i could see Source field is empty here,

find_real_file.png