ConnectionProperties problem

Compares and synchronizes SQL Server databases, backups and scripts.

Moderators: JonathanWatts, Chris Auckland, David Atkinson, eddie davis, Anu Deshpande, Michelle Taylor, alice.easey, james.billings, chengvoon.tong

ConnectionProperties problem

Postby kavaler » Thu Dec 06, 2012 11:26 am

Hi!
I have a little problem with connection to Database.
Code:
using (Database dbSource = new Database(), dbTarget = new Database())
{
// create connection to DB
Console.WriteLine("Registering databases...");
dbSource.Register(new ConnectionProperties("TRON\\\\KAVALER", "db3", "sa", "1"), Options.Default);
dbTarget.Register(new ConnectionProperties("kavasql", "db4", "sa", "2"), Options.Default);
Console.WriteLine("Comparing Databases...");
//code...
}

===============================================

dbTarget.Register(new ConnectionProperties("kavasql", "db4", "sa", "2"), Options.Default); - connection is set

dbSource.Register(new ConnectionProperties("TRON\\\\KAVALER", "db3", "sa", "1"), Options.Default); - connection is failed

Problem with serverName - "TRON\\\\KAVALER" .
Error: "ExecuteReader: CommandText property has not been initialized"
How i should type serverName correct?
kavaler
 
Posts: 1
Joined: Thu Dec 06, 2012 11:10 am

Return to SQL Compare 10

Who is online

Users browsing this forum: No registered users and 0 guests