How to add a Multi-Row Variable set from a record producer to the target table.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-10-2022 06:22 AM
Hello, I have a record producer that contains a multi-row variable set. I want the values for this field to be copied over to the record created by the record producer. I was wondering how I can do that. Thanks.
- Labels:
-
Scripting and Coding
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-10-2022 06:33 AM
Are you expecting the multi-row variables to be copied to description?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-10-2022 02:17 PM
Not really. I want the field and the multirow variable set to show up on the form. Maybe under something like variables
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-10-2022 07:31 AM
Hi,
Add below code in record producer script
Note : replace "mrvs_2" with your multirow variable set name
//Type appropriate comment here, and begin script below
var mRow = producer.mrvs_2; // replace "mrvs_2" with your multirow variable set name
var mRowObj = JSON.parse(mRow);
for (i = 0; i < mRowObj.length; i++) {
current.short_description = mRowObj[i].test; // test is name of the variable present in the MRVS
}
In my case I am updating multirow variable set data to short description
Multirow variable set data is copied to Short Description
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-10-2022 08:47 PM