"CreateFromIntersection" - Can't see all tables

Automate and integrate using the SQL comparison API

"CreateFromIntersection" - Can't see all tables

Postby ampo » Mon Jun 22, 2009 6:23 am


After getting Source DB tables and Target DB tables, I user CreateFromIntersection to get list of tables from both.

I have a table that 100% exists in both but it isn't in the result list...

Any idea why it isn't there?

Thanks for your help.
Posts: 8
Joined: Thu May 21, 2009 6:19 am

Postby Brian Donahue » Mon Jul 06, 2009 11:48 am

In order for CreateFromIntersection to map tables, the tables must have "matching" primary keys or unique indexes in both databases.

All tables and views should appear in the mappings collection if the names and schemata match up, but they may be ineligible for comparison.

Programatically, you can check the "Status" property on each mapping to see if the data in the mapped table or view will actually be compared. If not, then you can add primary keys or map manually. Please see the following KB for example code.

http://www.red-gate.com/support/Knowled ... apping.pdf
Brian Donahue
Posts: 6590
Joined: Mon Aug 23, 2004 9:48 am

Return to SQL Comparison SDK Previous Versions

Who is online

Users browsing this forum: No registered users and 0 guests