Virtual Flow Designer : Search text in KB Name/Title only with specific text

haffiez5181
Tera Contributor

Hi Expert,

 

I am new in Virtual Designer and basically having zero knowledge in scripting.

 

Actually I am trying to create an action using "Script Action Utility" to search related Knowledge Based based on the text input by user. The search will only look for text under the KB Title/Name instead the content body.

 

Sample that I have as per below.

 

(function execute() {
vaVars.query = vaInputs.sap_support_selection.getDisplayValue();
})()
 
The above script will search the text word by word, meaning that currently it will populated all the KB with the matching words. I am using OOTB Contextual Search Block to populate the KBs.
 
For example: 
 
Input by user: Issue with SAP default printer.
KB populated : All KBs with -issue-, -with-, -SAP-, -printer- in it.
What I want: The script only searching for KB title/name with matching -Issue with SAP default printer-
 
 
I tried to search about this however did not find match result, probably I am using wrong keyword to search.
 
I would be very appreciate if anyone can help with this. Thanks in advance.
1 REPLY 1

Abbas_5
Tera Sage
Tera Sage

Hello @haffiez5181,
Please refer to the below link:
https://www.servicenow.com/community/employee-center-forum/want-to-fetch-a-value-after-specific-text...

 

If it is helpful, please mark it as a thumbs-up and accept the correct solution.
Thanks & Regards,
Abbas Shaik