📅  最后修改于: 2022-03-11 15:00:03.229000             🧑  作者: Mango
Import-Module SqlChangeAutomation
<# ------- Compare a source database with a target database --------#>
$iReleaseArtifact = new-DatabaseReleaseArtifact `
-Source 'Server=MyFirstServer;Database=MyDatabase;User Id=Phil;Password=WhoKnows;Persist Security Info=False' `
-Target 'Server=MySecondServer;Database=MyOtherDatabase;User Id=Phil;Password=HeavenOnlyKnows;Persist Security Info=False' `
<# now display the results as an HTML page #>
$iReleaseArtifact.ReportHtml> "$env:TEMP\changes.html"
Start "$env:TEMP\changes.html