K2

Defining K2 Process Data Fields

K2 Process Data Fields

For those of you that are familiar with a programming language, Data Fields can be seen as a variable. For those of you that are not, a Data Field is simply a place holder for information that can later be accessed from anywhere within the K2 workflow.

The simplest way to create a K2 Data Field is by using the K2 Context Browser. The K2 Context Browser can be accessed from various points throughout the K2 workflow. For example, when we create a new SmartObject Event, we are asked to choose the applicable K2 SmartObject. Even at this point we have access to K2 Data Fields. To view the available Data Fields or create new ones, open the Context Browser and click on the “Process/Activity Data” tab. Expand the “Data Fields” node in the tree view.

Figure 1 – Process or Activity tab in the Context Browser

Figure 1 – Process or Activity tab in the Context Browser

Each of the processes in your workflow will appear under the “Data Fields” node in the Process/Activity data section of the Context Browser. In this example we only have one called “Process1”. In order to add a new Data Field, right click on the process, and click on the “Add” button.

k2 process data fields - Figure 2 – Opening the Add Data Field dialog

Figure 2 – Opening the Add Data Field dialog

Now the “Add Data Field” dialog will appear. Start off by giving the Data Field a name that will easily identify the purpose of the Data Field. In this example, I want to return a value from the database called “User ID” and save it into the data field, so I will name the Data Field “User ID”.

Figure 3 - Adding a new Data Field

Figure 3 – Adding a new Data Field

Next, select the Data Type of the Data Field you are adding, in this case I will select “Integer”. In this example I will not be selecting a Category or entering an Initial Value of Meta data. However feel free to do so at this point.

For the description field I will give a brief description of why I am creating this Data Field in order to make it easier for me later on to identify the purpose of the Data field.

In this example I will not check or uncheck any of the checkboxes below the description field.

Figure 4 - Completed Data Field Dialog

Figure 4 – Completed Data Field Dialog

Now click on the “OK” button to complete the process. Notice now that the User ID data field has been added to the “Process1” process in the Context Browser.

Figure 5 - Newly added Data Field

Figure 5 – Newly added Data Field

When data gets stored in a Data Field, we have “Global” access to that data field from any of the workflow items. Make sure you set the value of your Data Field before trying to user the data field from somewhere else. When you are ready to use your Data Field, simply browse to the “Process/Activity Data” tab in the Context Browser, and select the Data Field you wish to use. It’s that simple!

About K2

K2 is an enterprise Business Process Management tool that combines workflow, forms, data and reporting into a powerful affordable platform to create business applications with.  It is the leading BPM tool on Microsoft technology and are used my over 2000+ customer world wide to automate business processes.   More about K2 solutions here.

K2 Process Data Fields

You may also like

Leave a comment

PODCAST  |  Why you need to establish a K2 Center of Excellence today

Interview with Arno van Rooyen, CEO, Velocity