Archive for May, 2017

Nintex 2010 Updating Database ServerName Connection String

May 23, 2017 Leave a comment

I recently restored a Nintex 2010 Workflow Content Database from my production environment to my Disaster Recorvery (DR) SharePoint Farm. I wanted to purge Nintex Workflow History and old Workflows from the database to reduce the number of WorkflowProgress records in the database.

After restoring a backup of the Nintex 2010 Workflow Content database from Production to DR in SQL 2012 I tried to run the Nintex PurgeHistoryListData command:

nwadmin.exe -o PurgeHistoryListData -siteURL https://portal/site/workflows -day 180

When doing so I ran into the following error:

“Command line execution error: A network-related or instance-specific erorr occured while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. ”

This error happens because the Nintex 2010 Workflow Content Database that was restored to the DR environment had the wrong ServerName connection string set in the database.

If you go to Cental Administration -> Nintex Workflow Management > Database Setup you will see the Data Source is still pointing to the Production SQL server connection.

To be able to update this, you will need to update the Connection String within SQL Server Management Studio (SSMS)

1. Remote/Log into SQL Server 2012
2. Launch SSMS
3. Find the Nintex 2010 database (NW2010DB)
4. Expand the database (+)
5. Expand Tables (+)
6. Find the dbo.Database table
7. Right click database table and select “Select Top 1000 Rows”
8. The query will return all databases associated with the Nintex Configuration database (NW2010DB)
9. Within the results you will see the DatabaseName and ServerName values. You will notice in the ServerName its pointing to the Production SQL Server ServerName for the database that was just restored.
10. This value will need to be updated to point to the SQL Server the database was restored to.
11. Run the following T-SQL command. (Make sure you make a backup of the NW2010DB) database just in case.


Replace ‘NEW SQL SERVER\INSTANCE’ and ‘OLD SQL SERVER\INSTANCE’ with your SQL Servers and Instances.

Once the query runs it will update the connection string with the new ServerName.

12. Go back to run the Nintex Purge command and it should now execute without error.

If you run into a similar issue. Make sure the ServerName connection string is pointing to the correct SQL Server\Instance withing SQL.

Categories: Uncategorized