Skip to main content
May 17, 2024
Question

saving new data to subset

  • May 17, 2024
  • 2 replies
  • 0 views
id
1 group Mailing
Task Storage
Assignee refId Name
1 John Doe
2 Jane Doe
2 group Mailing
Task Reminder
Assignee refId Name
1 John Doe
2 Jane Doe

Hi I have 1 to many relationship between Group (level1) and Assignee (level 2)..

I want to update update and save the the name in Assignee.Name.

I have been using these one below and it did not work

a!forEach(
items: {"John Doe 1" , "Jane Doe 1", "Sam Doe 1"},
expression: {

a!save(ri!group [recordtype!group.relationship.Assignee.Name][fv!index],fv!item),

}
)

but it was not saved or overridden the Name Field.

i'm looking to save the output like this.

id
1 group Mailing
Task Storage
Assignee refId Name
1 John Doe 1
2 Jane Doe 1
Sam Doe
2 group Mailing
Task Reminder
Assignee refId Name
1 John Doe 1
2 Jane Doe 1
Sam Doe

could you please help?

2 replies

mikes0011
Brainy
May 17, 2024

"a!save()" won't do anything in an a!forEach statement.  It must be used in the saveInto parameter of a user-interactable field.

kend0001Author
May 17, 2024

It is just that I cannot index the second level.

It save it as first level.

I have this

saveInto:{

a!forEach(
items: {"John Doe 1" , "Jane Doe 1", "Sam Doe 1"},
expression: {

a!save(ri!group [recordtype!group.relationship.Assignee.Name][fv!index],fv!item),

}
)

}