Populate related list with glide list items?

patrykprejs
Tera Contributor

Hi all,

 

I am trying to figure out a way for my related list to populate from a glide list that we currently use.

 

We use a Glide list  for Changes and I would like to add that to a new related list that would then display the changes that get added to the list.

 

Is there a way for me to populate the below information into a related list:

patrykprejs_0-1698054330690.png

 

I have tried with a script but am clearly doing something wrong or missing something, I am pretty new to the scripting therefore any advise is appreciated.

 

Here is the relationship:

 

patrykprejs_1-1698054542458.png

 

As stated before any help would be appreciated, the above script displays no changes at all in the related list, the only thing I managed to achieve is for it to show all changes in general which is the wrong outcome. Thank you.

 

 

 

1 ACCEPTED SOLUTION

Ankur Bawiskar
Tera Patron
Tera Patron

@patrykprejs 

try this

current.addQuery('sys_id', 'IN' , parent.change);

If my response helped please mark it correct and close the thread so that it benefits future readers.

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

View solution in original post

2 REPLIES 2

Ankur Bawiskar
Tera Patron
Tera Patron

@patrykprejs 

try this

current.addQuery('sys_id', 'IN' , parent.change);

If my response helped please mark it correct and close the thread so that it benefits future readers.

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

That worked like a charm, thank you @Ankur Bawiskar!