Is it possible to configure the Windows Workflow SqlWorkflowPersistanceService to use different table/procedure names

StackOverflow https://stackoverflow.com/questions/1631730

  •  06-07-2019
  •  | 
  •  

Question

Is it possible to configure the Windows Workflow SqlWorkflowPersistanceService to use different SQL Server table/procedure names than the standard out of the box installation as detailed on Microsoft's site at http://msdn.microsoft.com/en-us/library/ms735722(VS.85).aspx ?

I have to store my workflow information in a shared SQL server database which has an established naming standard for tables and procedures which the standard setup provided by Microsoft doesn't comply with.

Can I easily map the SqlWorkflowPersistanceService to use different table names/procedure names or do I have to completly roll my own service if I want this change?

Was it helpful?

Solution

There is no way to tell the SqlWorkflowPersistanceService to use different stored procedures. Their names are coded into the assembly. AFAIK the SqlWorkflowPersistanceService only access tables through stored procedures so you could change all those stored procedures to point to different table names. Not sure if the work, and risk, is worth the benefit though.

An alternative is to write tour own WorkflowPersistanceService. I wrote a SqlCeWorkflowPersistenceService using LINQ to SQL last year and you can adopt that and change the table names. It will work against SQL server as is, the only thing I left out was the workflow ownership part as that is not relevant with SQLCe. You can download the code from here.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top