Values Not getting Inserted. Please help
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-13-2025 09:35 PM
Hello all,
I have written on before Transform Script and the logs are giving the values but not setting the values into the record created. Any idea why they are not inserting?
I tried with the commented lines as well.
Regards,
Lucky
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-13-2025 09:43 PM - edited 07-13-2025 09:45 PM
Hi @Lucky1 ,
have u checked the table identification rule whether that is preventing insertion.
And alternatively you can try same script in onAfter transform script and verify
Please mark helpful if it works for you
Thanks, GP
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-13-2025 10:54 PM
Hi ,
Thanks for your reply.
Yes, I checked in the CI class manager, there are no rules defined on this table.
One more thing is, I tried inserting a record using background scripts, but it is creating empty record but without values.
What could be the reason?
Regards,
Lucky
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-13-2025 11:28 PM
Hi @Lucky1 ,
I tried with below code and it created record in business application table from background script.
setWorkflow(false) is optional. you can try once.
If I could help you with your Query then, please hit the Thumb Icon and mark as Correct !!
Thanks, GP
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-13-2025 09:46 PM
this is onBefore or onAfter transform script?
which logs came?
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader