【问题标题】:Code Alignment In SQL Server 2008?SQL Server 2008 中的代码对齐?
【发布时间】:2012-06-26 11:28:58
【问题描述】:

我正在使用 SQL Server Management Studio。我想知道在 Visual Studio 中轻松对齐 T-SQL 查询类似于 ctrl+k+d 的快捷方式。

【问题讨论】:

  • Oracle 的 SQL Developer 有一个名为“美化器”的函数——唯一让它伤心的是 WITH 语法。我想念在 PLSQL 中的开发... :(

标签: sql sql-server-2008 text-alignment


【解决方案1】:

抱歉,您只能使用 3rd 方工具,例如 SSMS Tools Pack(免费)或 Red Gate stuff(非免费)

【讨论】:

    【解决方案2】:
    CTRL-SHIFT-F2         -- Clear all bookmarks. 
    CTRL+F2               -- Insert or remove a bookmark (toggle). 
    F2                    -- Move to next bookmark. 
    SHIFT+F2              -- Move to previous bookmark. 
    ALT+BREAK             -- Cancel a query. 
    CTRL+O                -- Connect. 
    CTRL+F4               -- Disconnect. 
    CTRL+F4               -- Disconnect and close child window. 
    ALT+F1                -- Database object information. 
    CTRL+SHIFT+DEL        -- Clear the active Editor pane. 
    CTRL+SHIFT+C          -- Comment out code. 
    CTRL+C or Ctrl+Insert -- Copy
    CTRL+X or Shift+Del   -- Cut
    SHIFT+TAB             -- Decrease indent. 
    CTRL+DEL              -- Delete through the end of a line in the Editor pane. 
    CTRL+F                -- Find. 
    CTRL+G                -- Go to a line number. 
    TAB                   -- Increase indent. 
    CTRL+SHIFT+L          -- Make selection lowercase. 
    CTRL+SHIFT+U          -- Make selection uppercase. 
    CTRL+V or Shift+Insert-- Paste. 
    CTRL+SHIFT+R          -- Remove comments. 
    F3                    -- Repeat last search or find next. 
    CTRL+H                -- Replace. 
    CTRL+A                -- Select all. 
    CTRL+Z                -- Undo. 
    F5 or Ctrl + E        -- Execute a query. 
    F1                    -- Help for Query Analyzer. 
    SHIFT+F1              -- Help for the selected Transact-SQL statement. 
    F6                    -- Switch between query and result panes. 
    Shift+F6              -- Switch panes. 
    CTRL+W                -- Window Selector. 
    CTRL+N                -- New Query window. 
    F8                    -- Object Browser (show/hide). 
    F4                    -- Object Search. 
    CTRL+F5               -- Parse the query and check syntax. 
    CTRL+P                -- Print
    CTRL+D                -- Display results in grid format. 
    CTRL+T                -- Display results in text format. 
    CTRL+B                -- Move the splitter. 
    CTRL+SHIFT+F          -- Save results to file. 
    CTRL+R                -- Show Results pane (toggle). 
    CTRL+S                -- Save
    CTRL+SHIFT+INSERT     -- Insert a template. 
    CTRL+SHIFT+M          -- Replace template parameters. 
    CTRL+L                -- Display estimated execution plan. 
    CTRL+K                -- Display execution plan (toggle ON/OFF). 
    CTRL+I                -- Index Tuning Wizard. 
    CTRL+SHIFT+S          -- Show client statistics 
    CTRL+SHIFT+T          -- Show server trace. 
    CTRL+U                -- Use database
    

    【讨论】:

    • 发帖时要多注意格式。您的帖子无法阅读。
    • 这些快捷方式中的大多数也与问题无关。也许全部。
    猜你喜欢
    • 1970-01-01
    • 2015-07-27
    • 1970-01-01
    • 2012-01-09
    • 1970-01-01
    • 2012-04-03
    • 2014-05-12
    • 2015-10-22
    • 1970-01-01
    相关资源
    最近更新 更多