SQL 工具和实用程序的 SQL Server、 Azure SQL 数据库和 Azure SQL 数据仓库SQL Tools and Utilities for SQL Server, Azure SQL Database, and Azure SQL Data Warehouse

适用对象:yesSQL ServeryesAzure SQL 数据库yesAzure SQL 数据仓库yes并行数据仓库APPLIES TO: yesSQL Server yesAzure SQL Database yesAzure SQL Data Warehouse yesParallel Data Warehouse

若要管理(查询、监视等)数据库,需要一个工具。To manage (query, monitor, etc.) your database you need a tool. 虽然数据库可以在云中、Windows 上或 Linux 上运行,但工具不需与数据库在相同的平台上运行。While your databases can be running in the cloud, on Windows, or on Linux, your tool doesn't need to run on the same platform as the database.

有许多可用的数据库工具,因此本文提供的说明和指南介绍了一些可用于处理 SQL 数据库的工具。There are many database tools available, so this article provides descriptions and pointers to some of the available tools for working with your SQL databases. 如果不知道如何确定所需的工具,请参阅应使用哪种工具?If you need help deciding which tool you need, see Which tool should I use?.

管理数据库的 GUI 工具GUI tools to manage databases

下面是主要的图形用户界面 (GUI) 工具:The following are the main graphical user interface (GUI) tools:

工具Tool 描述Description 运行平台Runs on
Azure 数据 StudioAzure Data Studio Azure 数据 StudioAzure Data Studio 是一款轻型免费工具,用于管理数据库,无论数据库在何处运行。is a free, light-weight tool, for managing databases wherever they're running. 此预览版提供各种数据库管理功能,其中包括扩展的 Transact-SQL 编辑器以及可自定义的数据库操作状态见解。This preview release provides database management features, including an extended Transact-SQL editor and customizable insights into the operational state of your databases. Azure 数据 StudioAzure Data Studio 在 Windows、 macOS 和 Linux 上运行Azure 数据 StudioAzure Data Studio runs on Windows, macOS, and Linux.
SQL Server Management Studio (SSMS)SQL Server Management Studio (SSMS) 使用 SQL Server Management Studio (SSMS) 来查询、 设计和管理 SQL Server、 Azure SQL 数据库和 Azure SQL 数据仓库。Use SQL Server Management Studio (SSMS) to query, design, and manage your SQL Server, Azure SQL Database, and Azure SQL Data Warehouse. SSMS 在 Windows 上运行SSMS runs on Windows.
SQL Server Data Tools (SSDT)SQL Server Data Tools (SSDT) 将 Visual Studio 变成适用于 SQL Server、Azure SQL 数据库和 Azure SQL 数据仓库的强大开发环境。Turn Visual Studio into a powerful development environment for SQL Server, Azure SQL Database, and Azure SQL Data Warehouse. SSDT 在 Windows 上运行SSDT runs on Windows.
Visual Studio CodeVisual Studio Code 在安装 Visual Studio Code 之后, 请安装用于开发 Microsoft SQL Server、Azure SQL 数据库和 SQL 数据仓库的 mssql 扩展After installing Visual Studio Code, install the mssql extension for developing Microsoft SQL Server, Azure SQL Database, and SQL Data Warehouse. Visual Studio Code 在 Windows、 macOS 和 Linux 上运行Visual Studio Code runs on Windows, macOS, and Linux.

用于管理数据库的命令行工具Command line tools to manage databases

下面是主要的命令行工具:The following are the main command-line tools:

工具Tool 描述Description 运行平台Runs on
mssql-cli(预览版)mssql-cli (preview) mssql-cli 是一项用于查询 SQL Server 的交互式命令行工具。mssql-cli is an interactive command-line tool for querying SQL Server. Windows、 macOS 和 LinuxWindows, macOS, and Linux
sqlpackagesqlpackage sqlpackage是一个命令行实用工具,可以自动执行多个数据库开发任务。sqlpackage is a command-line utility that automates several database development tasks. macOS 和 Linux 版本的 sqlpackage 目前处于预览状态。macOS and Linux versions of sqlpackage are currently in preview. Windows、 macOS 和 LinuxWindows, macOS, and Linux
SQL Server PowerShellSQL Server PowerShell SQL Server PowerShell 提供了用于处理 SQL 的 cmdletSQL Server PowerShell provides cmdlets for working with SQL Windows、 macOS 和 LinuxWindows, macOS, and Linux
sqlcmdsqlcmd sqlcmd实用工具,可以输入 TRANSACT-SQL 语句、 系统过程和脚本文件的命令提示符处。sqlcmd utility lets you enter Transact-SQL statements, system procedures, and script files at the command prompt. Windows、 macOS 和 LinuxWindows, macOS, and Linux
bcpbcp 大容量复制程序实用工具 (bcp) 可以在 MicrosoftMicrosoft SQL ServerSQL Server 实例和用户指定格式的数据文件间大容量复制数据。The bulk copy program utility (bcp) bulk copies data between an instance of MicrosoftMicrosoft SQL ServerSQL Server and a data file in a user-specified format. Windows、 macOS 和 LinuxWindows, macOS, and Linux
mssql 脚本编写器 (预览版)mssql-scripter (preview) mssql 脚本专家是多平台命令行体验,用于编写脚本的 SQL Server 数据库mssql-scripter is a multi-platform command line experience for scripting SQL Server databases Windows、 macOS 和 LinuxWindows, macOS, and Linux
mssql-confmssql-conf mssql-conf 配置在 Linux 上运行的 SQL Server。mssql-conf configures SQL Server running on Linux. LinuxLinux

应该选择哪种工具?Which tool should I choose?

其他工具Additional tools

工具Tool 描述Description
配置管理器Configuration Manager 使用 SQL Server 配置管理器来配置 SQL Server 服务并配置网络连接。Use SQL Server Configuration Manager to configure SQL Server services and configure network connectivity. 在 Windows 上运行 configuration ManagerConfiguration Manager runs on Windows
SQL Server Migration AssistantSQL Server Migration Assistant 使用 SQL Server Migration Assistant 自动将数据库从 Microsoft Access、DB2、MySQL、Oracle 和 Sybase 迁移到 SQL Server。Use SQL Server Migration Assistant to automate database migration to SQL Server from Microsoft Access, DB2, MySQL, Oracle, and Sybase.
数据库实验助手Database Experimentation Assistant 使用数据库实验助手来评估给定工作负荷的目标的 SQL 版本。Use Database Experimentation Assistant to evaluate a targeted version of SQL for a given workload.
Distributed ReplayDistributed Replay 使用 Distributed Replay 功能来帮助您评估将来的 SQL Server 升级的影响。Use the Distributed Replay feature to help you assess the impact of future SQL Server upgrades. 此外使用 Distributed Replay 来帮助评估硬件和操作系统升级和 SQL Server 优化的影响。Also use Distributed Replay to help assess the impact of hardware and operating system upgrades, and SQL Server tuning.
ssbdiagnosessbdiagnose Ssbdiagnose 实用工具可报告 Service Broker 对话或 Service Broker 服务的配置中的问题。The ssbdiagnose utility reports issues in Service Broker conversations or the configuration of Service Broker services.

如果您正在寻找在此页上未提及的其他工具,请参阅SQL 命令提示实用工具If you're looking for additional tools that are not mentioned on this page, see SQL Command Prompt Utilities.