Download and install SqlPackage
SqlPackage runs on Windows, macOS, and Linux.
Download and install the latest releases:
| Platform | Download | Release date | Version | Build |
|---|---|---|---|---|
| Windows | MSI Installer | May 24, 2022 | 19.1 | 16.0.6161.0 |
| macOS .NET Core | .zip file | May 24, 2022 | 19.1 | 16.0.6161.0 |
| Linux .NET Core | .zip file | May 24, 2022 | 19.1 | 16.0.6161.0 |
| Windows .NET Core | .zip file | May 24, 2022 | 19.1 | 16.0.6161.0 |
For details about the latest release, see the release notes. To download additional languages, see the Available Languages section.
DacFx
SqlPackage is a command-line interface for the DacFx framework, exposing some of the public DacFx APIs. DacServices (Microsoft.SqlServer.Dac) is a related mechanism for integrating database deployment into your application pipeline. The DacServices API is available in a package through NuGet, Microsoft.SqlServer.DacFx. The current DacFx version is 160.6161.0.
Installing the NuGet package via the .NET CLI is accomplished with this command:
dotnet add package Microsoft.SqlServer.DacFx
Note
Additional NuGet packages were published under the DacFx name, "Microsoft.SqlServer.DacFx.x64" and "Microsoft.SqlServer.DacFx.x86". Support for both platforms is covered under the "Microsoft.SqlServer.DacFx" package. New references should be made to this package, not the x64 or x86 variants.
Automated environments
Evergreen links are available for downloading the latest Sqlpackage versions:
- Linux (https://aka.ms/sqlpackage-linux)
- macOS (https://aka.ms/sqlpackage-macos)
- Windows (https://aka.ms/sqlpackage-windows)
- Windows, .NET Framework (https://aka.ms/dacfx-msi)
Linux (.NET Core)
Download SqlPackage for Linux.
To extract the file and launch SqlPackage, open a new Terminal window and type the following commands:
$ cd ~ $ mkdir sqlpackage $ unzip ~/Downloads/sqlpackage-linux-<version string>.zip -d ~/sqlpackage $ echo "export PATH=\"\$PATH:$HOME/sqlpackage\"" >> ~/.bashrc $ chmod a+x ~/sqlpackage/sqlpackage $ source ~/.bashrc $ sqlpackageNote
On Debian, Redhat, and Ubuntu, you may have missing dependencies. Use the following commands to install these dependencies depending on your version of Linux:
Debian:
$ sudo apt-get install libunwind8Redhat:
$ yum install libunwind $ yum install libicuUbuntu:
$ sudo apt-get install libunwind8 # install the libicu library based on the Ubuntu version $ sudo apt-get install libicu55 # for 16.x $ sudo apt-get install libicu57 # for 17.x $ sudo apt-get install libicu60 # for 18.x $ sudo apt-get install libicu66 # for 20.x
macOS (.NET Core)
Download SqlPackage for macOS.
To extract the file and launch SqlPackage, open a new Terminal window and type the following commands:
$ mkdir sqlpackage $ unzip ~/Downloads/sqlpackage-osx-<version string>.zip -d ~/sqlpackage $ chmod +x ~/sqlpackage/sqlpackage $ echo 'export PATH="$PATH:~/sqlpackage"' >> ~/.bash_profile $ source ~/.bash_profile $ sqlpackageNote
Security settings may require modification to run SqlPackage on macOS. Use the following commands to interact with Gatekeeper from the command line.
Before executing SqlPackage:
$ sudo spctl --master-disableAfter executing SqlPackage:
$ sudo spctl --master-enable
Windows (.NET Core)
Download SqlPackage for Windows.
To extract the file by right clicking on the file in Windows Explorer, and selecting 'Extract All...', and select the target directory.
Open a new Terminal window and cd to the location where SqlPackage was extracted:
> sqlpackage
Windows (.NET Framework)
This release of SqlPackage includes a standard Windows installer experience, and a .zip:
- Download and run the DacFramework.msi installer for Windows.
- Open a new Command Prompt window, and run SqlPackage.exe
- SqlPackage is installed to the
C:\Program Files\Microsoft SQL Server\160\DAC\binfolder
- SqlPackage is installed to the
Uninstall SqlPackage
If you installed SqlPackage using the Windows installer, then uninstall the same way you remove any Windows application.
If you installed SqlPackage with a .zip or other archive, then delete the files.
Supported Operating Systems
SqlPackage runs on Windows, macOS, and Linux and is built using .NET Core 3.1. The .NET Core 3.1 OS requirements apply to SqlPackage.
Windows (x64)
- Windows 11
- Windows 10 (1607+)
- Windows 8.1
- Windows 7 SP1
- Windows Server Core
- Windows Server 2012 R2
- Windows Server 2016
- Windows Server 2019
- Windows Server 2022
macOS
- macOS 12 "Monterey"
- macOS 11 "Big Sur"
- macOS 10.15 "Catalina"
Linux (x64)
- Debian 9, 10, 11
- Red Hat Enterprise Linux 7+
- SUSE Linux Enterprise Server v12 SP2+
- Ubuntu 16.04, 18.04, 20.04
Available Languages
This release of SqlPackage can be installed in the following languages:
SqlPackage Windows:
Chinese (Simplified) | Chinese (Traditional) | English (United States) | French | German | Italian | Japanese | Korean | Portuguese (Brazil) | Russian | Spanish
SqlPackage .NET Core Windows:
Chinese (Simplified) | Chinese (Traditional) | English (United States) | French | German | Italian | Japanese | Korean | Portuguese (Brazil) | Russian | Spanish
SqlPackage .NET Core macOS:
Chinese (Simplified) | Chinese (Traditional) | English (United States) | French | German | Italian | Japanese | Korean | Portuguese (Brazil) | Russian | Spanish
SqlPackage .NET Core Linux:
Chinese (Simplified) | Chinese (Traditional) | English (United States) | French | German | Italian | Japanese | Korean | Portuguese (Brazil) | Russian | Spanish
Next Steps
- Learn more about SqlPackage
Maklum balas
Kirim dan lihat maklum balas untuk