for a list it return all value, but if i add attribute under it, it just keep return multiple value of the list first value

As pictures show, i wish to save all list of value to database, but once i add attribute under it, it one keep returning value of the list's first value, why? Is this the defect of appian software it self?

  Discussion posts and replies are publicly visible

Parents
  • hello, hope this help Slight smile

    The target parameter accepts a list of variables, in this case you are wrongly passing all the current ids of your rule input variable (2000,2001,200), instead pass them one by one
    in order to make it work you must perform the save as follows

    a!forEach(
    items: ri!csetenderphases,
    expression: a!save(
    fv!item.id,
    /*just an example, find out the right index for the local list*/
    index(
    local!csetenderphaseslist,
    fv!index,
    null
    )
    )
    )

Reply
  • hello, hope this help Slight smile

    The target parameter accepts a list of variables, in this case you are wrongly passing all the current ids of your rule input variable (2000,2001,200), instead pass them one by one
    in order to make it work you must perform the save as follows

    a!forEach(
    items: ri!csetenderphases,
    expression: a!save(
    fv!item.id,
    /*just an example, find out the right index for the local list*/
    index(
    local!csetenderphaseslist,
    fv!index,
    null
    )
    )
    )

Children
No Data