Query and Text Editors (SQL Server Management Studio)
You can use one of the SQL Server Management Studio editors to interactively edit and test a Transact-SQL, MDX, DMX, or XML/A script, or to edit an XML or plain text file. Each editor is supported by a language-specific service that colors keywords, and checks for syntax and usage errors. The Database Engine Query Editor includes a Transact-SQL debugger that you can use to help fix problems in Transact-SQL code.
The four editors in Management Studio share a common architecture. The text editor implements the base level of functionality, and can be used as a basic editor for text files. The other three editors, or query editors, extend this base of functionality by including a language service that defines the syntax of one of the languages supported in SQL Server. The query editors also implement varying levels of support for editor features such as IntelliSense and debugging. The query editors include the Database Engine Query Editor for use in building scripts containing Transact-SQL and XQuery statements, the MDX editor for the MDX language, the DMX editor for the DMX language, and the XML/A editor for the XML for Analysis language.
|
Task Description |
Topic |
|---|---|
|
Describes how to view and use the basic features in the Database Engine Query Editor. |
|
|
Describes how to view and use the basic features in the MDX Query Editor. |
MDX Query Editor (Analysis Services - Multidimensional Data) |
|
Describes how to view and use the basic features in the DMX Query Editor. |
|
|
Describes how to view and use the basic features in the XML/A Editor. |
|
|
Describes how to configure options for the various editors, such as line numbering and IntelliSense options. |
|
|
Describes the various ways you can open the editors in Management Studio. |
|
|
Describes how to manage the view mode, such as word wrap, splitting a window, or tabs. |
|
|
Describes how to set formatting options, such as hidden text or indentation. |
|
|
Describes how to navigate through the text in an editor window by using features such as incremental search or go to. |
|
|
Describes how to set color coding options for various classes of syntax, which makes it easier to read complex statements. |
|
|
Describes how to use code outlining to hide parts of complex scripts that you are not currently working on. |
|
|
Describes how to drag text from one location in a script and drop it in a new location. |
|
|
Describes how to do global search and replace, such as when changing column names. |
|
|
Describes how to set bookmarks in order to more easily find important pieces of code. |
|
|
Describes how to print scripts or the results in a window or grid. |
|
|
Describes how to use the sqlcmd features in the Database Engine Query Editor. |
|
|
Describes how to use IntelliSense features such as auto-completing object names as you type them, or ensuring breakpoints are placed in valid locations. |
|
|
Describes how to use code snippets in the Database Engine Query Editor. Snippets are templates for commonly used statements or blocks, and can be customized or extended to include site-specific snippets. |
|
|
Describes how to use the Transact-SQL debugger to step through code and view debugging information such as the values in variables and parameters. |
|
|
Describes how to set custom colors for different instances of the Database Engine, and have those colors set as the background of the status bar in Database Engine Query Editor windows. |