Restoring and Executing SQL created fromt the BlockSaver

kfilipowskykfilipowsky Posts: 14
edited December 14, 2006 10:41AM in SQL Toolkit Previous Versions
The BlockSaver creates a file containing the TSQL used to sync 2 databases. Can you suggest a way to restore this SQL to a Batch object so execution can take place at a later date.


We're not going to use the ToolKit in a typical Database syncronization fasion but rather to Promote objects through environments as part of our automated CMS. Once an object is selected for for promotion, it must go through an approval process which could take days. It is not acceptable to get a refreshed copy of that object as it may have changed.


Thanks in advance

Comments

  • Brian DonahueBrian Donahue Posts: 6,590 New member
    Hi Karl,

    I'm not sure if there is a better way to do this, but you could get your code to build some kind of XML representation of the ExecutionBlock and another 'reader' to read this file back in later to create a new ExecutionBlock...

    ...Or you could consider creating a package using the Packager API. This is essentailly what packager does; it creates an XML document describing the ExecutionBlock and puts it in a .NET resource as part of a Visual Studio project. This project is then compiled using CodeDOM into an executable file that will run the SQL.
Sign In or Register to comment.