Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

Parent and child tickets

Ankitha4
Tera Contributor

We are facing a issue where child tickets are not changing status to on hold when pareng is changed to on hold .

And assignment group of child ticket is also not changing .can you please help what may be the reason for that issue 

5 REPLIES 5

Dr Atul G- LNG
Tera Patron
Tera Patron

Hi @Ankitha4 

AGLearnNGrow_0-1710434239408.png

 

https://youtu.be/Agw0HNuqe2M

 

Have  look here, you wil get the answer.

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.

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/atul_grover_lng [ Connect for 1-1 Session]

****************************************************************************************************************

Thanks Atul for the reply. May I know why the assignment group is not changing

Hi @Ankitha4 

 

This is OOTB configuration, means Assignment group will not copied  updated in child incident.

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.

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/atul_grover_lng [ Connect for 1-1 Session]

****************************************************************************************************************

Amit Pandey
Kilo Sage

Hi @Ankitha4 

 

You can do this by writing before business rule-

 

if (current.state.changes() && current.state == '4') { // Assuming '4'  is status 'On Hold' 
        
        var childTicketGr = new GlideRecord('ChildTicketTable'); // Replace with actual child table name
        childTicketGr.addQuery('parent', current.sys_id); 
        childTicketGr.query();

        while (childTicketGr.next()) {
        
            childTicketGr.state = '4'; // Assuming '4' is the status 'On Hold' for child tickets
            childTicketGr.assignment_group = current.assignment_group; 
            childTicketGr.update();
        }
    }

 

Please mark my answer helpful and correct.

 

Regards,
Amit