Contextual search for one catalog item

prathyusha_snow
Tera Contributor

I wanted to add a contexual search for a short description field. Can any one help me how to do that?

1 ACCEPTED SOLUTION

I did this is a OOTB Helsinki instance.



All I did was: Change the reference field of the "Record producer" field in the "Record Producer Configuration" table. Then to test it, I created a new Record Producer Configuration, specified a Cat item (in my case I took the example cat item "New Email Account"), specified a search context "Knowledge Base Search". Specified a search variable which was a string: "Preferred Email address". And that's it, I saved the configuration record and it automatically created a "Contextual Search Result" UI Macro variable inside the item and it was working without any error.



Maybe you could try in a personal developer instance and than look for what is different between that instance and yours related to that configuration.


View solution in original post

6 REPLIES 6

Brad Tilton
ServiceNow Employee
ServiceNow Employee

The following article shows how to add contextual search to a record producer and it should be pretty similar to add to a catalog item.



Provide knowledge in incident record producer


Hi Brad,



Thanks for a quick reply. I wanted to do it on a catalog item instead of a record producer. I tried creating a search context, but it doesn't work for a catalog item.


Hi,



I did try to switch the reference of the Record producer field (in Record Producer Configuration) to sc_cat_item instead of sc_cat_item_producer. It did work, however I don't know if this should be done as I don't understand why it is set to record producers only OOTB.


Hi Laurent,



That's an impressive idea. Thank you so much. I'll try it and see if that works for me . Thank you again.