Importing knowledge Article
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-30-2025 04:53 AM - edited 12-30-2025 04:58 AM
Hi Team,
I have a knowledge article document in word format, in that there is a two fields like summary field and symptoms field having contents once I upload the word document , both the summary field and symptoms field names should be erased and the contents of those fields should get updated into the there is a description field available on the knowledge article, for this need a fix script.
need the above contents should get updated in the description field like below.
Kindly help on this to achieve.
Regards,
Abhilasha G T
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-30-2025 05:15 AM
Hi @Abhilasha G T ,
You can fix this by creating a Before Business Rule on the table that runs when a record is created. The rule will get the Description field value, remove the field names like Summary and Symptoms, and clean the content before the record is inserted into the database.
business rule script :
add this script in your businness rule
var desc = current.description + '';
// Remove field names "Summary" and "Symptoms" (case-insensitive)
desc = desc.replace(/^Summary\s*/im, '');
desc = desc.replace(/^Symptoms\s*/im, '');
// Remove extra line breaks
desc = desc.replace(/\n+/g, '\n').trim();
// Update the Description field
current.description = desc;
if you already have too many records in the table then you can run the background script or fix scripts
thanks,
tejas
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-30-2025 06:24 AM
Hi @Tejas Adhalrao ,
Thanks for your reply , its not working.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-30-2025 06:29 AM
Hi @Abhilasha G T I’m not sure what your use case is, but before you proceed, please check whether the description field length is sufficient to store both the summary and the description together. I don’t think combining everything is a good approach. We faced a similar issue earlier when importing data into the system in the same way. It would be better to first implement the solution properly and then make the change, or run a script to fix the issue afterward.
Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/dratulgrover [ Connect for 1-1 Session]
****************************************************************************************************************
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-30-2025 07:21 AM
Hi @Dr Atul G- LNG ,
Thanks for your reply, yes i have checked the description field length also its max length is 4000 , its sufficient as of now.
