Controlling your workflow database transactions is what comes naturally to this Next Generation BPM solution.

workflow database transaction

SQL Workflow Instance

With cDevWorkflow’s workflow database transaction tool, a single process step may execute N number of SQL statements.  cDevWorkflow’s transaction support feature enables your BPM design to control database transaction changes.

Controlling your workflow database transactions is what comes naturally to this Next Generation BPM solution.  With cDevWorkflow your workflow database transaction data is committed only if there are no errors.  If there are detectable key stoke or missing information field errors then cDevWorkflow permits database roll back to the before attempted change state.

cDevWorkflow’s extended data access layer fully supports the workflow database transaction support requirements of todays high end databases.

Here’s an example of code that will execute without any transactions:

clsDataAccess oDA = new clsDataAccess(sConnStr);
Hashtable oDic = new Hashtable();
oDic["deUserID"] = Guid.NewGuid().ToString();
oDic["deExternalUserName"] = "dataman";
oDic["deExternalUserFullName"] = "defulluser";
oDA.insertRecord("deUsers", oDic);
oDA.insertRecord("deUsers", oDic);
oDA.Disconnect();

Based on the code detailed above, there are 2 statements performing insert records commands.  The second statement fails because of a primary key failure.  But the first statement execute successfully and inserts a workflow database transaction record.

Here’s an example of code that will execute with transactions:

clsDataAccess oDA = new clsDataAccess(sConnStr);
oDA.beginTransaction();
Hashtable oDic = new Hashtable();
oDic["deUserID"] = Guid.NewGuid().ToString();
oDic["deExternalUserName"] = "dataman";
oDic["deExternalUserFullName"] = "defulluser";
try
{
     oDA.insertRecord("deUsers", oDic);
    oDic["deUserID"] = Guid.NewGuid().ToString();
    oDA.insertRecord("deUsers", oDic);
    DataTable oDT = oDA.GetDataTable("select * from deusers");
    oDA.commitTransaction();
}
catch (Exception ex)
{
    oDA.rollbackTransaction();
}
oDA.Disconnect();

The above code uses transactions and performs the same insert records as the code before.  But since the 2nd insert statement fails, the transaction rolls back and no records are inserted into the database.  Workflow database calls made with this transaction support make sure no orphan data is left behind from failed database calls.

A small sampling of the Workflow Technology for BPM Solutions contained within our cDevWorkflow product offering can be found here: Workflow Technology That Works.

Learn more about our Process Automation & IT, QA Services or Software Development products and solutions on the Web!  Visit us at: Innovative Process Solutions