Solved

Triggering a new workflow based on status change

  • 4 March 2019
  • 3 replies
  • 51 views

We implemented a new process using K2 at the first of the year. This process once approved, inserts into an existing database where we track our projects.

 

The next phase of this process was once the status changed in the existing database it then goes and changes the status of the record in the K2 database where the new process is and starts a new workflow for another process. This all works great except for records that were already in the old process that weren’t part of the original K2 process but of the old process.

 

How can I get pre-existing records in the existing database to run in the new K2 process?

icon

Best answer by EmilyK 6 March 2019, 01:39

View original

3 replies

Badge +15

What kind of information are you trying to fetch for the old processes?


 

existing records that were pre k2 workflow in the other database. It works fine if it had gone through the new process but when I have a status change on a project pre-k2 new process, it doesn't pick it up and I believe it is since it wasn't part of the k2 process.

Badge +10
Are you looking to trigger it from a change in a SQL column? If so, you might be able to use something like this: https://k2recipes.wordpress.com/portfolio/start-k2-workflow-from-sql-server-using-net-class-library/

You might also be able to create a console application to start the process instance and use a SQL trigger to execute it when the value in the database is changed.

Reply