Query List Nintex workflow action for Office 365 SharePoint Online

Query List Nintex workflow action

In this post, we will discuss how we can user Query List Nintex workflow action for Office 365 Online. Apart from this, we will also see how we can use For Each, Get-Item From Collection Nintex workflow actions.

In this demo, we will see how we can query a SharePoint list data and the by using For each and Get Item from Collection we will log into the history list.

SharePoint deveopment training course

If you are new to Nintex Workflow for Office 365, read Step by Step Nintex Workflow tutorial for Office 365 SharePoint Online.

Nintex Workflow Query List action helps us to query data from a SharePoint Online list in the current site. In this case, we will create a site workflow using Nintex Workflow for Office 365.

To Create a Site Workflow, go to your SharePoint online Site Contents page. Then click on the Nintex Workflow for Office 365 app in that page. This will open the Nintex workflow Gallery. Here click on Create New Site Workflow button which will open your workflow designer.

In the workflow actions section, search for Query List workflow action. Drag and drop a Query List action to the workflow. Then search for a For Each action and then drag and drop down to Query List action. After that Drag and drop Get Item from Collection inside for each loop in Nintex Workflow for Office 365. Then add one Log to History List action into the site workflow.

So now your Nintex workflow should look like below:

Query List Nintex workflow action
Query List Nintex workflow action

Then we need to add few variables like a blow, either you can create form the Variables button in the ribbon or you can also create while configuring each step.



nintex workflow sharepoint 2013
nintex workflow sharepoint 2013

Now we will configure each action. Double click on Query List workflow action to open the configure dialog box. First, select the List name from where you want to query data. Here I have chosen Editor mode as Query builder and choose the option to show all items. At the same time, you can also add some filter criteria. Then Sort based on a column.

Then you can choose Maximum number rows to show at a time (default value 100).

  • Output Type: There are two options for output.
  • Single output: Outputs all selected columns to a single collection variable.
  • Separate output per column: Outputs each selected column to its own collection variable.

Then we can select the columns we want to select. Then set the Output to a collection type variable which we have created earlier or you can create a new variable of a collection type.

Then in Result count select a variable of type Integer. This will store the number of results returned from the Query. It should look like below:

nintex workflow examples
nintex workflow examples

Then double-click on the For Each loop. Then:

  • Input dictionary or collection: Choose the collection variable.
  • Output value: Choose the single line text variable which will store the value of the variable item accessed from the dictionary or collection variable.
  • Output index: Select the integer variable for storing the index of the collection variable item.

It should look like below:

query list nintex workflow
query list nintex workflow




Then double-click on Get Item From Collection workflow action to open the configuration wizard. Choose the target collection as ItemCol variable. Index choose the MyItemIndex variable. The Output variable chooses myItemTitle variable. This variable will store the retrieved item.

how to use for each loop in nintex workflow
how to use for each loop in nintex workflow

Then double-click on the Log To History List workflow action as shown in the fig below, Here choose myItmeTitle variable. It should look like below:

how to use for each loop in nintex workflow
how to use for each loop in nintex workflow

Now Publish the workflow which we have just created using Nintex Workflow for Office 365. Since this is a site workflow. To run the workflow, go to the Site Contents page, Then click on Site Workflows link. It will show you all the workflows, Click on the workflows to run the workflow. Once the workflow runs successfully completed., you can see the history list, all the items are listed.


You may like following Nintex Workflow for Office 365 tutorials:

Hope this Nintex workflow helps to use Query List Nintex workflow Office 365 actions in SharePoint Online. Then will tell you how to use For Each, Get-Item From Collection Nintex workflow actions in SharePoint Online Office 365.

Check out Best Alternative to InfoPath -> Try Now

free sharepoint training

SharePoint Online FREE Training

JOIN a FREE SharePoint Video Course (3 Part Video Series)

envelope
envelope

About Bijay Kumar

I am Bijay from Odisha, India. Currently working in my own venture TSInfo Technologies in Bangalore, India. I am Microsoft Office Servers and Services (SharePoint) MVP (5 times). I works in SharePoint 2016/2013/2010, SharePoint Online Office 365 etc. Check out My MVP Profile.. I also run popular SharePoint web site SharePointSky.com

View all posts by Bijay Kumar →