The CreatorCon Call for Content is officially open! Get started here.

How to combine 2 array fields?

Zod
Giga Guru

Hi,

for a string I can do something like this ... current.u_field1 =   current.u_field1 + current.u_field2; current.update();

... but how to do this if both fields are arrays?

Thank you!

1 ACCEPTED SOLUTION

Have a read of this thread about why not to use current.update()



Never use current.update in a Business Rule



try the below script, it's saying, if the current watch list is not empty, get the value and add it to the work notes.



if(!current.watch_list.nil()){


var watch = current.getValue('watch_list');


current.work_notes_list += ',' + watch;


}


View solution in original post

16 REPLIES 16

Thank you!!!


HAve a great time ... I need to work 3 more hours ;-/


OOOOOOOOOOOOOOMG.


It was a fu***** typo in the variable!!!



Just reviewed all after having a beer ... and there it was 😉


Thanks a lot. Working now!!