RegisterForDataCompare with ScriptFolderPath is in what SDK?

Automate and integrate using the SQL comparison API

Moderator: Chris Auckland

RegisterForDataCompare with ScriptFolderPath is in what SDK?

Postby ccollins » Tue Dec 20, 2011 10:26 pm

// NOTE - always pass null for Script Database Information in Data Compare (will read script settings from the xml file in the folder)
430. dScriptFolder.RegisterForDataCompare(sScriptFolderPath, null, Options.Default);


I only have one overload with my SDK8. It wants connectionproperties or connectionproperties with options, I don't have one that I can pass a path to.

According to the release notes SDK8 can data compare a live database to scripts. Am I missing an update maybe?
ccollins
 
Posts: 50
Joined: Wed Jun 22, 2005 7:49 pm

Postby Brian Donahue » Wed Dec 21, 2011 10:16 am

I'm sure it's the latest SDK, our SDK documentation is just going unloved. I'll see if I can get someone to fix it. Meanwhile, product support have put up a wiki or code samples that *should* be in the documentation but aren't: http://sdk.red-gate.com/index.php/SQL_Comparison_SDK

There is a good example you can use for scripts folders here.
Brian Donahue
 
Posts: 6668
Joined: Mon Aug 23, 2004 10:48 am

troubleshooting registerfordatacompare and folders

Postby ccollins » Wed Dec 21, 2011 6:21 pm

I added all required red-gate references from C:\\Program Files (x86)\\Red Gate\\SQL Comparison SDK 8\\Assemblies\\SQL Data Compare\\. Then created a new solution with the scripts folder example: http://sdk.red-gate.com/index.php/Scripts_Folder

C:\\Program Files (x86)\\Red Gate\\SQL Comparison SDK 8\\Assemblies\\SQL Data Compare\RedGate.SQLCompare.Engine.dll v7.1.0.182
RedGate.SQLDataCompare.Engine.dll v7.1.0.230

The build fails:
\\StaticDataWithScriptsExample.cs(325,21): error CS0246: The type or namespace name 'ScriptDatabaseInformation' could not be found (are you missing a using directive or an assembly reference?)
\\StaticDataWithScriptsExample.cs(325,76): error CS0246: The type or namespace name 'ScriptDatabaseInformation' could not be found (are you missing a using directive or an assembly reference?)
\\StaticDataWithScriptsExample.cs(327,65): error CS0103: The name 'ScriptEncodingType' does not exist in the current context
\\StaticDataWithScriptsExample.cs(328,21): error CS1502: The best overloaded method match for 'RedGate.SQLCompare.Engine.Database.SaveToFolder(string, RedGate.SQLCompare.Engine.ReadFromFolder.WriteToFileOptions)' has some invalid arguments
\\StaticDataWithScriptsExample.cs(328,67): error CS1503: Argument '2': cannot convert from 'ScriptDatabaseInformation' to 'RedGate.SQLCompare.Engine.ReadFromFolder.WriteToFileOptions'
\\StaticDataWithScriptsExample.cs(367,39): error CS0117: 'RedGate.SQLCompare.Engine.ReadFromFolder.FolderDataSource' does not contain a definition for 'DoesDatabaseInformationFileExist'
\\StaticDataWithScriptsExample.cs(416,21): error CS1501: No overload for method 'RegisterForDataCompare' takes '3' arguments
c:\\Program Files (x86)\\Red Gate\\SQL Comparison SDK 8\\Assemblies\\SQL Data Compare\\RedGate.SQLCompare.Engine.dll: (Related file)
\\StaticDataWithScriptsExample.cs(480,30): error CS0117: 'RedGate.SQLDataCompare.Engine.SqlProvider' does not contain a definition for 'Synchronize'

Compile complete -- 8 errors, 0 warnings
========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ==========
ccollins
 
Posts: 50
Joined: Wed Jun 22, 2005 7:49 pm

environment information

Postby ccollins » Wed Jan 04, 2012 2:14 pm

I have SQL Data Compare 7 installed, which does not support script data to database data comparison. I have SQL Compare 8 and now 10 installed which both support script to database comparision. Is the SQL Data Compare 7 installation preventing success with the sdk 8 script data registration?

The example continues failing to build.
ccollins
 
Posts: 50
Joined: Wed Jun 22, 2005 7:49 pm


Return to SQL Comparison SDK Previous Versions

Who is online

Users browsing this forum: No registered users and 0 guests