@mani55 

the reason it's not working is you are querying but not going to the actual record with next() method

update() method will create a dummy record if it's used directly

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

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