Click here to Skip to main content
15,890,579 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Actually in my current Application i call the Connection string by using a XML file and i used Merge replication for maintain two databases in two different servers. what i want is if the connection to main database(publisher) fails i want to automatically switch my connection string to other one(subscriber DB )with out minimum delay and after Main DB recovered from the issue( ex :server failure) then it should again connected to the Application and subscriber DB should synchronized with publisher DB. if some one Knows the proper Switching Mechanism for achieving this task. Thanks in advance .
Posted
Updated 27-Apr-12 20:41pm
v5

1 solution

The right way to do this would be to use SQL Server Clustering and create a failover cluster. Your code doesn't have to do anything special at all. The situation is handled entirely server side.

You can read up on it here[^].
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900