"Object reference not set to an instance of an object."

Automate and integrate using the SQL comparison API

Moderators: Chris Auckland, David Atkinson, Michelle Taylor, chengvoon.tong

"Object reference not set to an instance of an object."

Postby Philn » Sat Feb 02, 2013 12:19 am

Hi,
I am not sure what am I missing when run the following code..
(note- I copied almost exactly as the same as in the the code sample)
The error happen on the line "work.BuildFromDifferences(diffs, Options.Default, true);"

...
TableMappings mappings = new TableMappings();
mappings.CreateMappings(srcDB.Tables, destDB.Tables);
mappings.Options = new EngineDataCompareOptions(
MappingOptions.Default,
ComparisonOptions.TrimTrailingSpaces | ComparisonOptions.Default,
SqlOptions.Default);
Differences diffs = srcDB.CompareWith(destDB, Options.Default);
foreach (Difference diff in diffs)
{
diff.Selected = true;
}
Work work = new Work();
work.BuildFromDifferences(diffs, Options.Default, true);
//Perform sync
ExecutionBlock block = work.ExecutionBlock;
BlockExecutor executor = new BlockExecutor();
philn
Philn
 
Posts: 7
Joined: Fri Feb 01, 2013 11:53 pm

Postby Brian Donahue » Mon Feb 04, 2013 11:54 am

I'm sorry you have encountered this issue. I will be responding to you via email with the information relevant to troubleshooting this problem.

Thanks!
Brian Donahue
 
Posts: 6670
Joined: Mon Aug 23, 2004 10:48 am


Return to SQL Comparison SDK 10

Who is online

Users browsing this forum: No registered users and 0 guests