Can I check if item is unique (based on title field) via nintex workflow before adding list item? That would be great.
SharePoint can check on unique item (title column), but still adds the item.
The nintex workflow gives an error message and stops, but the sharepoint list still holds these 'duplicate' records with no value in title.
Or can I delete these duplicate items in list afterwards ?
Solved! Go to Solution.
Nintex workflows can only run on an existing item. So you wouldn't be able to prevent an item from being created using workflows. However after an item is created, you could use a Query list to check if an item already exists with the same title as the new item, and if you find a match, delete the new item.
Nintex Forms, which is a separate product, may give you the ability to run a rule before submitting an item to check if there is a duplicate item. We don't have that so I couldn't say for sure, but someone else on here could probably answer that.
There are several ways to accomplish this. One way would be to use the Query List action with a filter (this can be set in the Query Action's configuration screen) set to check against the title of the item you are trying to add. This way if you get a result, you know that an item with that title already exists. You could then delete the item before adding it again, or choose to update the item, using one of the many other actions found within Nintex Worfklow.
Hope that helps!
I have a list where I need to be able to not allow a person to submit a new item if the item already exists (in this case, the item is the person's name as it is a membership list.) Would this solution work for my issue or do you have any other ideas on how to accomplish this? Thank you in advance!
Yes, you could use a very similar concept to accomplish this. Basically you are querying the list to see if the item exists or not before allowing it to go through. What you could do is utilize 2 lists to accomplish this if you wanted to. Basically the form could submit to the first list, and then a workflow could process that list and see if the item should be created in the "final" membership list. This way the first list just acts as a queue of sorts for processing against and gives you buffer between the in process items and the finalized list. There are plenty of other solutions out there as well. You could probably stop them at the form level as well by using a lookup on the form and seeing if the item already exists and if so just disabling their ability to save the form.
Mike M - I'm trying to implement your last statement above:
You could probably stop them at the form level as well by using a lookup on the form and seeing if the item already exists and if so just disabling their ability to save the form
However, in the lookup control the actual value includes 4;# in front of the actual title, since it's a lookup (where the 4 is the ID number in the lookup list).
Would you provide some more detail?
Use the parseLookup function to remove the 4;# information (works well on a calculated field doing a lookup), or you could write a rule based on "contains" logic if you'd rather not do the parsing and are sure the value would be unique. Let me know if that helps!
Mike - thanks for the tip - I was trying to use the list lookup by mistake. Shortly after I posted this, my co-worker came up with a similar idea using the calculated field.
It was a 3 part solution since I was trying to parse the current user's account:
1) calculated field (PreferredName)
2) Calculated field (calcCheckDuplicateItem)
3) Used a rule to hide body of the form (and the save button) and put a notice indicating that they had already added an item and could not add another.
thanks for the input...
How to check item is unique (base on title field) via nintex workflow before adding to subfolder？I try to use Query List to filter the same name item, but can't get the item in subfolder, is there any other way?Thx~！