| Author |
Message |
SB
Joined: 07 Feb 2008 Posts: 2
|
Posted: Thu Feb 07, 2008 12:47 am Post subject: Sample XML Files etc. |
|
|
Hello,
I am looking for sample XML files to be used with SQL Packager CLI. Essentially, here is what I am planning to do.
- Compare schema between two databases and generate script
- Compare data between two databases and generate script
- Exclude certain tables when comparing Data (e.g. System Tables etc)
- Create an EXE to apply the changes as needed.
- Create a Script File that will list all of the changes that EXE will apply.
I am plannning to automate this so that our nightly builds can pickup the .EXE and merge them in our process as needed. Script file will be used for documentation only.
Thank you. |
|
| Back to top |
|
 |
Brian Donahue
Joined: 23 Aug 2004 Posts: 6369 Location: Red Gate Software
|
Posted: Mon Feb 11, 2008 6:53 pm Post subject: |
|
|
Hello,
This shouldn't be a problem. The following example shows some options you can use with the XML command file to sqlpackager.exe. To create the package, you run sqlpackager.exe /argfile:<name of XML command file>
| Code: |
<?xml version="1.0"?>
<commandline>
<!-- connection properties-->
<server1>MyComputer\MyServer</server1>
<database1>WidgetDev</database1>
<username1>sa</username1>
<password1>p@ssw0rd</password1>
<server2>MyComputer\MyServer2</server2>
<database2>WidgetLive</database2>
<username2>sa</username2>
<password2>P@ssw0rd</password2>
<!--System tables are ignored anyway...-->
<excludeschema>\[dbo\].\[WidgetPrices\]</excludeschema>
<excludedata>table:\[dbo\].\[WidgetDescriptions\]</excludedata>
<excludedata>table:\[dbo\].\[WidgetPrices\]</excludedata>
<!-- Output the schema and data scripts-->
<schemascript>c:\temp\schema.sql</schemascript>
<datascript>c:\temp\datascript.sql</datascript>
<!-- build options -->
<makeexe />
<force />
<location>c:\temp</location>
<name>MyPackage</name>
</commandline>
|
_________________ Brian Donahue
Technical Support
Red Gate Software Ltd.
44 (0)870 160 0037 ext 8521
US and CAN 1-866-RED GATE ext 8521 |
|
| Back to top |
|
 |
SB
Joined: 07 Feb 2008 Posts: 2
|
Posted: Mon Feb 11, 2008 11:36 pm Post subject: |
|
|
Thank you Brian. I will try it out and post back if I have any questions.
BTW: Where can I get a list of options? I didn't see them in the help file for CLI.
Thanks. |
|
| Back to top |
|
 |
Brian Donahue
Joined: 23 Aug 2004 Posts: 6369 Location: Red Gate Software
|
Posted: Tue Feb 12, 2008 10:10 am Post subject: |
|
|
Hi,
The help is pretty minimal for the command-line. You'll get the full list of options from SQL Packager itself:
| Code: |
| sqlpackager /? /verbose |
_________________ Brian Donahue
Technical Support
Red Gate Software Ltd.
44 (0)870 160 0037 ext 8521
US and CAN 1-866-RED GATE ext 8521 |
|
| Back to top |
|
 |
|
|
All times are GMT + 1 Hour
|
| Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group