Slow query from "Tasks by Same Company" relationship causes slow /new_call.do form loadsDescriptionBuild information:glide-newyork-06-26-2019__patch3-hotfix3-12-15-2019 glide-newyork-06-26-2019__patch7a-04-06-2020Issue Description:When loading a new_call.do form, the form can take a long time to load due to the "Tasks by Same Company" relationship.Steps to Reproduce Have a lot of data in the TASK table.1. Navigate to the new_call list2. Open a record.Expected behavior: It should not take along time to load the related lists for the new_call record.Actual behavior: It can take a long time to load the related lists for the new_call record.WorkaroundKindly modify the relationship code to be like this: Record: https://<instance>.service-now.com/sys_relationship.do?sys_id=6640d41eeb000100eac006a2f206feba Query with:var company = parent.company; if (JSUtil.notNil(company)) { var inc = "sys_class_name=incident^active=true^ref_incident.caller_id.company=" + company; var prb = "sys_class_name=problem^active=true^opened_by.company=" + company; var chg = "sys_class_name=change_request^active=true^ref_change_request.requested_by.company=" + company; var scr = "sys_class_name=sc_request^active=true^ref_sc_request.requested_for.company=" + company; var v_array_of_sys_id = []; var grinc = new GlideRecord('task'); grinc.addEncodedQuery(inc); grinc.query(); while (grinc.next()) { v_array_of_sys_id.push(grinc.sys_id + ''); } var grprb = new GlideRecord('task'); grprb.addEncodedQuery(prb); grprb.query(); while (grprb.next()) { v_array_of_sys_id.push(grprb.sys_id + ''); } var grchg = new GlideRecord('task'); grchg.addEncodedQuery(chg); grchg.query(); while (grchg.next()) { v_array_of_sys_id.push(grchg.sys_id + ''); } var grscr = new GlideRecord('task'); grscr.addEncodedQuery(scr); grscr.query(); while (grscr.next()) { v_array_of_sys_id.push(grscr.sys_id + ''); } current.addEncodedQuery("sys_idIN" + v_array_of_sys_id.join(',')); } else current.addEncodedQuery("sys_idISEMPTY"); Alternatively, you could just as easily replace the one relationship with 4 related lists. NOTE: The PRB is fixed in Quebec, once this version is available then kindly upgrade the instance to the fixed version. Related Problem: PRB1412429