workflow to populate a column based on 2 conditions

Jump to solution

I am using SharePoint 2013.  

I have a list called Projects with:

--a single line of text column called ProjectName

--a multiple lines of text column called RiskInfo

I have another list called Risks with:

--a single line of text column called RiskName

--a lookup column that allows multiple values called ImpactedProjects. This gets information from the Projects list in the ProjectName column. The user selects the values when filling out the Nintex form.

--a choice column called RiskClosed (Yes, No)


I would like a site workflow that will update the RiskInfo column in the Projects list with all RiskNames, separated by commas, where RiskClosed=No and ImpactedProjects=ProjectName.


Ex: in my Risk list:

RiskName: Risk1

Impacted Projects: Proj1, Proj2, Proj 3

RiskClosed: No


RiskName: Risk2

Impacted Projects: Proj1, Proj3

RiskClosed: No


Then in my Project list, the workflow would populate the RiskInfo columns:

ProjectName: Proj1

RiskInfo: Risk1, Risk2


ProjectName: Proj2

RiskInfo: Risk1


ProjectName: Proj3

RiskInfo: Risk1, Risk2


I don’t have experience with workflows. Can anyone help?



0 Kudos
2 Replies

Re: workflow to populate a column based on 2 conditions

Jump to solution

Hi @rutica,

this should be pretty straightforward.

You basically have 3 options:

  1. Update your project when it gets changed (List Workflow on list Projects)
  2. Update all projects when a risk gets changed (List Workflow on list Risks)
  3. Have a workflow running on cycles and update all projects (Site Workflow)

2 and 3 can be realised as follows:

List Settings: In Risks go to List Settings and add the ID column to ImpactedProjects



col_ProjectIDs collection
tmp_str_Id single line of text
col_RiskNames collection
  1. Insert a Query List action and retrieve the IDs of all projects (no filter) in col_ProjectIDs
  2. Inser a ForEach Action: Collection: col_ProjectIDs Store result in: tmp_str_Id
    1. Insert a query List Action (Please note: in tmp_str_ID there now is the list item id of a project)
      List: Risks
      Filter: ImpactedProjects:ID equals tmp_str_ID AND RiskClosed == "No"
      Field: RiskTitle -> col_RiskNames
    2. Insert some build string magic to make it look better if needed
    3. Insert an update Item action
      Update: Projects
      Where: ID equals Workflowvariable: tmp_str_Id
      Field: RiskInfo <- col_RiskNames (or the beautified value from (2))
0 Kudos

Re: workflow to populate a column based on 2 conditions

Jump to solution

Hi @Tarf 


Please forgive me for not replying sooner! I am truly sorry.

I tried your instructions above and it works perfectly. You are very smart! I would have never been able to figure this out but your instructions were clear and clever and I'm smiling ear to ear.


I'm usually a bit scared of workflows since I haven't used them very often and I usually run into problems when I try, but thanks to you, my fears are easing. :-) 


Thanks again!

0 Kudos