PowerShell Snippet #8 – Publish Dacpacs with DacFx


When it comes to publishing dacpacs, you can either use SQLPackage or DacFx, though in reality they are the same thing.

From a beginners POV, using SQLPackage makes sense because it is easier to work with. But many scripts used to deploy use DacFx.

Below is a script to deploy using DacFx.

If you’re wondering where am I getting DacFx from, then consider using #3 in this series and Microsoft.Data.Tools.MsBuild – Install NuGet Packages Using PowerShell


Leave a Reply

Your email address will not be published. Required fields are marked *