SQL Server 2005 custom shortcut keys

Source: Internet
Author: User
Tags management studio sql server management sql server management studio

Select menu in SSMs: Tools --Customize , tick "show shortcut keys in ScreenTips" so that when you hover over the execution icon, a prompt F5 is displayed. Shortcut keys do not need to rote, the mouse point when you look at the next time you can use the shortcut keys, with more than cooked.

SQL Server Management Studio supports custom shortcut keys: tools, options, keyboards :
Among them, Alt+f1, ctrl+1, ctrl+2 are predefined shortcut keys for the system.
Double-click the table name (or ctrl-click the table name) to select a table name, such as TableName, press ALT+F1, which is equivalent to performing "sp_help tablename" to view descriptive information about the object.


--CTRL+F1: Displays the first 100 rows of a table or view, and the selected tablename,1000 press CTRL+F1 to display the first 1000 rows of the table.

sp_executesql n ' IF object_id (@tablename) is not NULL EXEC (n "SELECT TOP" [Email protected]+n ' * from ' [email protected] ) ', N ' @tablename nvarchar (+), @n int=100 ',

--ctrl+3: Displays a definition script for views, stored procedures, functions, and triggers.
sp_helptext
--ctrl+4: Displays the number of rows and space for the table.
sp_spaceused
--ctrl+5: Displays the space occupied by each index in the table.
sp_executesql N ' SELECT index_name = Ind.name, Ddps.used_page_count, Ddps.reserved_page_count, Ddps.row_count from sys.indexes ind INNER JOIN sys.dm_db_partition_stats DDPs on ind.object_id = ddps.object_id and ind.index_id = Ddps.index_ ID WHERE ind.object_id = object_id (@tablename) ', N ' @tablename nvarchar ',
--ctrl+9: Displays the field names of the table or view, separated by commas.
sp_executesql N ' Select columns = STUFF ((SELECT ', ' +name from sys.columns WHERE object_id = object_id (@tablename) FO R XML PATH (""), "("), "") ', N ' @tablename nvarchar ',
--ctrl+0: Finds a table, view, stored procedure, function
in the current database based on the selected keyword sp_ ExecuteSQL N ' SELECT * from sys.objects WHERE type A (' U ', ' V ', ' P ', ' FN ') and name like '% ' [email protected]+ '% ' ORDER by Type,name ', N ' @keyword nvarchar ',

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.