how to iterate from list 1 & list 2 values at a time

Certified Associate Developer

Hello Everyone,

Can anyone help me on this, Thanks in Advance.

require to iterate from lists & save in cdt in above format.

  Discussion posts and replies are publicly visible

Parents
  • 0
    Certified Lead Developer

    The merge() function turns multiple lists into tuples picking items from each list at the same index.

    a!localVariables(
      local!list1: { "user1", "user2", "user3" },
      local!list2: { "userA", "userB", "userC" },
      a!forEach(
        items: merge(local!list1, local!list2),
        expression: a!map(
          contentOwners: fv!item[1],
          qcReviewers: fv!item[2],
        )
      )
    )

Reply
  • 0
    Certified Lead Developer

    The merge() function turns multiple lists into tuples picking items from each list at the same index.

    a!localVariables(
      local!list1: { "user1", "user2", "user3" },
      local!list2: { "userA", "userB", "userC" },
      a!forEach(
        items: merge(local!list1, local!list2),
        expression: a!map(
          contentOwners: fv!item[1],
          qcReviewers: fv!item[2],
        )
      )
    )

Children
No Data