How to get the record producer list collector variable to copy to a table each_list field

IB98
Giga Sage

Hello, 

I am trying to map a record producer list collector to a watch_list field on the table record. 

I have tried to use the map field option on the variable, but it looks like the variable vs the field types might be the reason that the mapping to field option does not work. I have also tried to set the variable attribute to glide_list and that did not work, at least how I had it configured. The script is also not working, as I had it configured. Did someone else solve this problem, if so, how?

Big Thanks!!!

1 ACCEPTED SOLUTION

Ankur Bawiskar
Tera Patron
Tera Patron

@IB98 

you can use record producer script field

did you print what came in logs?

current.watch_list = producer.listCollectorVariableName.toString()

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

4 REPLIES 4

Ankur Bawiskar
Tera Patron
Tera Patron

@IB98 

you can use record producer script field

did you print what came in logs?

current.watch_list = producer.listCollectorVariableName.toString()

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

Unfortunately, this did not work!!! I have tried it without the mapping of the field and with the mapping of the field. Thanks for your input 

@IB98 

so what came in log?

what debugging did you do?

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

Actually, this code worked. There was a BR that needed to be modified on the "sn_customerservice_case" table. The condition of the BR was changed to (gs.getUser().hasRole('sn_customerservice.relationship_agent') && !gs.getUser().hasRole('admin')) and the code worked in the script. Thanks 🙂