In the SSMS (currently running SQL Server 2008 R2), I would like to add the Description
property next to the Allow Nulls
property in the table designer window.
I have looked at the registry change for setting the default value of the null property as shown in this SO answer How do I set the Allow Nulls property in table designer of SSMS to be always false? However, I cannot figure out how to add the new property into the new table designer view.
I thought the the following registry entry would help.
HKEY_CURRENT_USER\Software\Microsoft\Microsoft SQL Server\100\Tools\Shell\DataProject\
SSVPropViewColumnsSQL70
SSVPropViewColumnsSQL80
I changed the registry entries of above keys from 1,2,6;
to 1,2,6,9;
but nothing changed in the designer.
Does anyone have any additional thoughts on this?
4条答案
按热度按时间uxhixvfz1#
Here are the steps to add a property to the table designer in SQL Server Management Studio. The steps involve altering the values in registry settings.
NOTE: Please be careful while altering registry keys.
HKEY_CURRENT_USER\Software\Microsoft\Microsoft SQL Server\100\Tools\Shell\DataProject
HKEY_CURRENT_USER\Software\Microsoft\SQL Server Management Studio\11.0\DataProject
SSVPropViewColumnsSQL70
andSSVPropViewColumnsSQL80
.1,2,6;
. Section Property sequence mentioned below shows the number associated with each property. For my requirement to add Description column to the table designer, I had to change the registry key values to1,2,6,17;
Modify
option. Change the value from1,2,6;
to1,2,6,17;
. This has to be done on both the keysSSVPropViewColumnsSQL70
andSSVPropViewColumnsSQL80
NOTE: Remember to restart SSMS between each registry change.
Property sequence:
Hope this helps someone.
x33g5p2x2#
For those of you looking for a .REG file to achieve this, copy/paste these lines into a text file with a .REG extension. Double click that to add it to your registry. The column numbers are listed in the answer by pithhelmet . The example below uses "14.0" meaning the version of SSMS that started being released as a standalone tool from SQL 2017 onwards. I expect that the registry path will continue to stay at 14.0 for some time yet, even with regular updates for SSMS being released.
Note that you need to have SSMS closed when you apply these changes to the registry.
bvk5enib3#
For SQL Server Management Studio Version 18.x (2019) and 19.x: First Close SQL Server Management Studio. then open Regedit and go to: "Computer\HKEY_CURRENT_USER\Software\Microsoft\SQL Server Management Studio\18.0_IsoShell\DataProject" and then Change the SSVPropViewColumnsSQL70 and SSVPropViewColumnsSQL80 Data from 1,2,6; to 1,2,6,17
ejk8hzay4#
For SQL-Server-Management Studio 2014 (SSMS 2014) it's a bit tricky to get the "Description" column (17):
2a) Open Regedit, goto: "HKEY_USERS\S-1...###YOUR-WINDOWS-USER-SID###-\SOFTWARE\Microsoft\SQL Server Management Studio\12.0\DataProject"
2b) Change the keys: SSVPropViewColumnsSQL70 and SSVPropViewColumnsSQL80 from 1,2,6; to 1,2,6,17;