cancel
Showing results for 
Search instead for 
Did you mean: 
rixdeanmcx
Nintex Newbie

Best approach for generating a new project number

Hello all, I have a SharePoint List that stores project data, my goal is to have the workflow loop through the list, get the Max project number by department, add 1 and store this value as next available number or possibly create it as a new item in a list of next available numbers. Each department project number series is unique and mostly do not start at 1. The format is 9999-999. left 4 are the department code, and right 3 are the project number we have 305 departments. I have accomplished this using InfoPath and SharePoint Designer basically by grouping by department, converting the right 3 of PJ number to a number, then Max of Pj nuber + 1. I have been tasked to create this same query process in Nintex. So far I have a collection variable (collProjectNumbers), variable (NewProjectNumber and a list query. What I need help with, when the user submits the new form with the appropriate Department and code the workflow will filter on that department only and get the next number. I am new to Nintex and not sure how to tackle this one with the most effective approach.

thank for any help.

Labels: (1)
Tags (1)
Reply
12 Replies
fhunth
Nintex Newbie

Re: Best approach for generating a new project number

Perhaps this article will help you >>> Sequential Numbering in SharePoint with Nintex Workflow 

0 Kudos
Reply
rixdeanmcx
Nintex Newbie

Re: Best approach for generating a new project number

The article ends at Part 1 and requires a subscription to view part 2, I subscribed and nothing happens? no part 2.

0 Kudos
Reply
Nintex Employee
Nintex Employee

Re: Best approach for generating a new project number

0 Kudos
Reply
abdullahfahmi91
Nintex Newbie

Re: Best approach for generating a new project number

Hi Richard McClanahan‌,

Probably what you can do is to have one list that keeps current running number for all department with 4 columns:

Dept Name - Dept Code - Previous Number - Current Number

And you can create another list for request record purpose.


Whenever a new request on the 2nd list comes, it will look for Dept Code from the 1st list and take the corresponding Current Number.

Combine with Dept Code and create a new project number. Then update to the request item on the 2nd list.

Then update Previous Number column with Current Number value and add 1 to Current Number column.

Reply
rixdeanmcx
Nintex Newbie

Re: Best approach for generating a new project number

Thanks for the direction, good approach. I actually have a form library for the request and approval which will trigger the workflow, I will add the "Next Available Number" list and get to work.

0 Kudos
Reply
abdullahfahmi91
Nintex Newbie

Re: Best approach for generating a new project number

If you think your question is answered, please mark this question as answered as this will be helpful for other users of Nintex Connect.

Reply
rixdeanmcx
Nintex Newbie

Re: Best approach for generating a new project number

thanks again Abdullah, I have a design that I think will work, I am using InfoPath for the request form and a list for project data, what I may need help with is after the new project is created I need a workflow to query the list, filter or group by department and either sort or get the Max project number and add 1. I am working on that now.

Reply
abdullahfahmi91
Nintex Newbie

Re: Best approach for generating a new project number

I think it would be easier to configure and maintain if you used two lists, one list for the request and one list for reference. By doing this, you can add new department and its code easily on the reference list.

0 Kudos
Reply
rixdeanmcx
Nintex Newbie

Re: Best approach for generating a new project number

Thank you for the response, I have this working nicely so far, User submits a request for a new number providing department information from a look up in the form which is a data connection to a list with all departments with department codes. When a new item is created (form submitted) in the request form library the workflow fires and creates a new item in the project inventory list. Then a workflow fires on new item with the above actions. The first variable is the department code which is used to filter the query,  all the projects for that department are stored in a collection variable and sorted Z-A using a number column [PJnumberRight3] then I perform the math to add 1, then I build the sting {Department code} - {NewNumber} then update the blank project number on the current item and the [PJnumberRight3] and update the form library request form with the new number like 9999-999. still working on the approval steps. So it seems my choice was to build another list or handle getting the max number using the list query. I will post my final solution once I am satisfied. thanks again I tried to stay with the InfoPath form because I have considerable time invested in the approval process.

Reply