SQL Server Management Studio 2016中的新选项

This article will introduce some minor, but very handy improvements in SSMS 2016, such as options for preventing the appearance of a dialog box for saving queries, setting up color of the interface theme, highlighting the current line and checking for a new SSMS updates.

本文将介绍SSMS 2016中的一些次要但非常方便的改进,例如用于防止显示用于保存查询的对话框的选项,设置界面主题的颜色,突出显示当前行以及检查新的SSMS更新。

在SQL Server Management Studio(SSMS)中保存打开的查询 (Save open queries in SQL Server Management Studio (SSMS))

In the earlier versions of SSMS when closing unsaved queries the Microsoft SQL Server Management Studio dialog box will appear with the option to save/not save or cancel closing operation:

在早期版本的SSMS中,当关闭未保存的查询时,将显示Microsoft SQL Server Management Studio对话框,其中包含保存/不保存或取消关闭操作的选项:

This can be excessive, especially if it is in the most cases chosen to not preserve the unsaved script. In SSMS 2016 there is a new option to skip this dialog box, by uncheck the Prompt to save unsaved T-SQL query windows on close option. By default, this option is turned on. To uncheck this option, go to the Tool menu and from the list, select the Options command, in the Options window, choose the SQL Server node, which is located under the Query Execution node and pick the General tab:

这可能是多余的,尤其是在大多数情况下,如果选择不保留未保存的脚本。 在SSMS 2016中,有一个新选项可以跳过此对话框,方法是取消选中“ 在关闭时保存未保存的T-SQL查询窗口提示”选项。 默认情况下,此选项处于打开状态。 取消选中此选项,转到工具菜单,然后从列表中选择选项命令,在选项窗口中,选择SQL服务器节点位于查询执行节点下,并选择在常规选项卡:

Now when closing unsaved query window, there will be no prompt to save the file.

现在,当关闭未保存的查询窗口时,将不会提示您保存文件。

搜索选项 (Search Options)

Another feature that is added in SSMS 2016 is Search Options, which is located on the top left side of the Options dialog window:

SSMS 2016中添加的另一个功能是“ 搜索选项” ,它位于“ 选项”对话框窗口的左上方:

This option search through the node that are located in the list below the Search Options search box:

此选项可搜索“ 搜索选项”搜索框下方列表中的节点:

Using shortcut Ctrl+E while in the Options window, the cursor will be automatically positioned in the Search Options box. Note, this shortcut is only active when is open the Options window.

在“ 选项”窗口中使用快捷键Ctrl + E,光标将自动定位在“ 搜索选项”框中。 注意,此快捷方式仅在打开“ 选项”窗口时才有效。

颜色主题 (Color theme)

In SSMS 2016 there are two colors to change theme. By default, the Blue color is set:

在SSMS 2016中,有两种颜色可以更改主题。 默认情况下,设置蓝色

To set a theme to different the Light color, go to the Tools menu and from the list, select the Options command, in the Options window under the Environment node, choose the General tab. In the Visual experience section from the Color theme combo box select Light option:

要将主题设置为不同的浅色 ,请转到“ 工具”菜单,然后从列表中选择“ 选项”命令,在“ 环境”节点下的“ 选项”窗口中,选择“ 常规”选项卡。 在“ 颜色” 主题组合框中的“ 视觉体验”部分,选择“ 灯光”选项:

The result will be:

结果将是:

突出显示当前行 (Highlighting current line)

When open the query editor in SSMS 2016 the first thing that notice is the gray square that surrounds the current position of the cursor:

在SSMS 2016中打开查询编辑器时,首先要注意的是围绕光标当前位置的灰色正方形:

By default, this option is turned on. To turn off this option, on the SSMS main menu, choose the Tools and from the Tools list select the Options command. From the Options window, select the Text Editor node and pick the General tab. On the Display section of the General tab, uncheck the Highlight current line option:

默认情况下,此选项处于打开状态。 要关闭此选项,请在SSMS主菜单上选择“ 工具”,然后从“工具”列表中选择“ 选项”命令。 在“ 选项”窗口中,选择“ 文本编辑器”节点,然后选择“ 常规”选项卡。 在“ 常规”选项卡的“ 显示”部分,取消选中“ 突出显示当前行”选项:

检查更新 (Check for update)

SSMS 2016 now has the option to check online for updates. If set to notify alerts for new updates SSMS will be presented as a toast notification:

SSMS 2016现在可以选择在线检查更新。 如果设置为通知警报有新更新,SSMS将作为敬酒通知显示:

If click on it, you will be redirected to the web page on which can be download new version of SSMS.

如果单击它,您将被重定向到可以下载新版本的SSMS的网页。

SSMS allows users to manually to check for updates as well, by clicking the Check for Updates option in the Tools menu:

SSMS还允许用户通过单击“ 工具”菜单中的“ 检查更新”选项来手动检查更新:

This will open the SQL Server Management Studio Updates window with details about updates:

这将打开“ SQL Server Management Studio更新”窗口,其中包含有关更新的详细信息:

To turn off automatic check for updates, uncheck the check box in the bottom of the SQL Server Management Studio Updates window:

若要关闭自动检查更新,请取消选中“ SQL Server Management Studio更新”窗口底部的复选框:

翻译自: https://www.sqlshack.com/new-options-in-sql-server-management-studio-2016/

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值