Tips and tricks for using sql server management studio (ssms)

Содержание:

Поддерживаемые компонентыSupported Features

В следующей таблице можно найти компоненты, которые поддерживаются в SQL ServerSQL Server в установке Server Core.Use the following table to find which features are supported in SQL ServerSQL Server on a Server Core installation .

КомпонентFeature ПоддерживаетсяSupported Дополнительные сведенияAdditional Information
СлужбыКомпонент Database EngineDatabase EngineКомпонент Database EngineDatabase Engine Services ДаYes
SQL ServerSQL Server РепликацияReplication ДаYes
Полнотекстовый поискFull Text Search ДаYes
Службы Analysis ServicesAnalysis Services ДаYes
Службы R (в базе данных)R Services (In-Database) ДаYes
Службы Reporting ServicesReporting Services НетNo
SQL ServerSQL Server Data Tools (SSDT)Data Tools (SSDT) НетNo
Средства связи клиентских средствClient Tools Connectivity ДаYes
Сервер служб Integration ServicesIntegration Services Server ДаYes
Обратная совместимость клиентских средствClient Tools Backward Compatibility НетNo
Пакет SDK клиентских средствClient Tools SDK НетNo
Электронная документация поSQL ServerSQL ServerSQL ServerSQL Server Books Online НетNo
Основные средства управленияManagement Tools — Basic Только удаленныеRemote Only Установка этих компонентов на Server Core не поддерживается.Installation of these features on Server Core is not supported. Эти компоненты могут быть установлены на сервере, отличном от Server Core, и подключены к службам Компонент Database EngineDatabase Engine, установленным в Server Core.These components can be installed on a different server that is not Server Core and connected to the Компонент Database EngineDatabase Engine services installed on Server Core.
Средства управления — полный наборManagement Tools — Complete Только удаленныеRemote Only Установка этих компонентов на Server Core не поддерживается.Installation of these features on Server Core is not supported. Эти компоненты могут быть установлены на сервере, отличном от Server Core, и подключены к службам Компонент Database EngineDatabase Engine, установленным в Server Core.These components can be installed on a different server that is not Server Core and connected to the Компонент Database EngineDatabase Engine services installed on Server Core.
Контроллер распределенного воспроизведенияDistributed Replay Controller НетNo
Клиент распределенного воспроизведенияDistributed Replay Client Только удаленныеRemote Only Установка этих компонентов на Server Core не поддерживается.Installation of these features on Server Core is not supported. Эти компоненты могут быть установлены на сервере, отличном от Server Core, и подключены к службам Компонент Database EngineDatabase Engine, установленным в Server Core.These components can be installed on a different server that is not Server Core , and connected to the Компонент Database EngineDatabase Engine services installed on Server Core.
Пакет SDK для подключения клиентов SQLSQL Client Connectivity SDK ДаYes
Microsoft Sync FrameworkMicrosoft Sync Framework ДаYes Платформа Microsoft Sync Framework не входит в установочный пакет SQL ServerSQL Server .Microsoft Sync Framework is not included in the SQL ServerSQL Server installation package. Вы можете скачать соответствующую версию Sync Framework в Центре загрузки Майкрософт (https://go.microsoft.com/fwlink/?LinkId=221788) и установить ее на компьютер, где работает установка Server Core.You can download the appropriate version of Sync Framework from this Microsoft Download Center (https://go.microsoft.com/fwlink/?LinkId=221788) page and install it on a computer that is running Server Core.
Службы Master Data ServicesMaster Data Services НетNo
Data Quality ServicesData Quality Services НетNo

Установка актуальной версии SQL Server Management Studio (SSMS)Install the newest version of SQL Server Management Studio (SSMS)

При работе с SQL Server следует всегда использовать последнюю версию SQL Server Management Studio (SSMS).When working with SQL Server, you should always use the most recent version of SQL Server Management Studio (SSMS). Актуальная версия SSMS постоянно обновляется и оптимизируется и сейчас работает с SQL Server на базе Linux.The latest version of SSMS is continually updated and optimized and currently works with SQL Server on Linux. Чтобы скачать и установить актуальную версию, перейдите на страницу скачивания SQL Server Management Studio.To download and install the latest version, see Download SQL Server Management Studio. Чтобы вы были в курсе последних новостей, актуальная версия SSMS выводит запрос при наличии новой версии, доступной для скачивания.To stay up-to-date, the latest version of SSMS prompts you when there is a new version available to download.

Примечание

Прежде чем использовать SSMS для управления Linux, ознакомьтесь с известными проблемами для SSMS в Linux.Before using SSMS to manage Linux, review the known issues for SSMS on Linux.

ПримерыExamples

Следующий скрипт открывает среду SQL Server Management StudioSQL Server Management Studio из командной строки с настройками по умолчанию:The following script opens SQL Server Management StudioSQL Server Management Studio from a command prompt with the default settings:

Следующие скрипты открывают SQL Server Management StudioSQL Server Management Studio из командной строки посредством проверки подлинности Active Directory — встроенная:The following scripts opens SQL Server Management StudioSQL Server Management Studio from a command prompt using Active Directory — Integrated:

Следующий скрипт открывает среду SQL Server Management StudioSQL Server Management Studio из командной строки с применением проверки подлинности Windows и с редактором кода, настроенным для сервера без показа экрана-заставки:The following script opens SQL Server Management StudioSQL Server Management Studio from a command prompt, with Windows Authentication, with the Code Editor set to the server without showing the splash screen:

Следующий скрипт открывает среду SQL Server Management StudioSQL Server Management Studio из командной строки и открывает скрипт MonthEndQuery:The following script opens SQL Server Management StudioSQL Server Management Studio from a command prompt, and opens the MonthEndQuery script.

Следующий скрипт открывает среду SQL Server Management StudioSQL Server Management Studio из командной строки и открывает проект NewReportsProject на компьютере с именем :The following script opens SQL Server Management StudioSQL Server Management Studio from a command prompt, and opens the NewReportsProject project on the computer named :

Следующий скрипт открывает среду SQL Server Management StudioSQL Server Management Studio из командной строки и открывает решение MonthlyReports:The following script opens SQL Server Management StudioSQL Server Management Studio from a command prompt, and opens the MonthlyReports solution:

Информация была полезной? Поделись с друзьями!

Проверка на вирусы

Управление серверными и клиентскими сетевыми протоколамиManage Server & Client Network Protocols

SQL ServerSQL Server позволяет настраивать серверные и клиентские сетевые протоколы, а также параметры подключения.Configuration Manager allows you to configure server and client network protocols, and connectivity options. После включения правильных протоколов обычно не нужно менять сетевые подключения сервера.After the correct protocols are enabled, you usually do not need to change the server network connections. В то же время диспетчер конфигурации SQL ServerSQL Server можно использовать для перенастройки соединений, чтобы SQL ServerSQL Server прослушивал определенный сетевой протокол, порт или канал.However, you can use SQL ServerSQL Server Configuration Manager if you need to reconfigure the server connections so SQL ServerSQL Server listens on a particular network protocol, port, or pipe. Дополнительные сведения о включении протоколов см. в разделе Включение или отключение сетевого протокола сервера.For more information about enabling protocols, see Enable or Disable a Server Network Protocol. Сведения о разрешении доступа к протоколам в брандмауэре см в разделе Настройка брандмауэра Windows для разрешения доступа к SQL Server.For information about enabling access to protocols through a firewall, see Configure the Windows Firewall to Allow SQL Server Access.

SQL ServerSQL Server Диспетчер конфигурации позволяет управлять серверными и клиентскими сетевыми протоколами, в том числе применять шифрование протокола, просматривать свойства псевдонима, а также включать и отключать протокол.Configuration Manager allows you to manage server and client network protocols, including the ability to force protocol encryption, view alias properties, or enable/disable a protocol.

Диспетчер конфигурации SQL ServerSQL Server позволяет создавать или удалять псевдонимы, изменять порядок использования протоколов и просматривать свойства псевдонима сервера, включая:SQL ServerSQL Server Configuration Manager allows you to create or remove an alias, change the order in which protocols are used, or view properties for a server alias, including:

  • псевдонимы сервера— псевдонимы сервера, используемый для компьютера, с которым соединяется клиент;Server Alias — The server alias used for the computer to which the client is connecting.

  • протокол — сетевой протокол, используемый для данной конфигурации;Protocol — The network protocol used for the configuration entry.

  • параметры соединения — параметры, связанные с адресом соединения для конфигурации сетевого протокола.Connection Parameters — The parameters associated with the connection address for the network protocol configuration.

Диспетчер конфигурации SQL ServerSQL Server позволяет также просматривать сведения об экземплярах отказоустойчивого кластера, хотя для некоторых действий, например запуска и остановки служб, должен использоваться администратор кластера.The SQL ServerSQL Server Configuration Manager also allows you to view information about failover cluster instances, though Cluster Administrator should be used for some actions such as starting and stopping the services.

Доступные сетевые протоколыAvailable Network Protocols

SQL ServerSQL Server поддерживает протоколы общей памяти, TCP/IP и именованных каналов.supports Shared Memory, TCP/IP, and Named Pipes protocols. Сведения о выборе сетевых протоколов см. в разделе Configure Client Protocols.For information about choosing a network protocols, see Configure Client Protocols. SQL ServerSQL Server не поддерживает сетевые протоколы VIA, Banyan VINES Sequenced Packet Protocol (SPP), Multiprotocol, AppleTalk и NWLink IPX/SPX.does not support VIA, Banyan VINES Sequenced Packet Protocol (SPP), Multiprotocol, AppleTalk, or NWLink IPX/SPX network protocols. Клиенты, подключенные ранее с помощью этих протоколов, для соединения с SQL ServerSQL Serverдолжны выбрать другой протокол.Clients previously connecting with these protocols must select a different protocol to connect to SQL ServerSQL Server. Диспетчер конфигурации SQL ServerSQL Server нельзя использовать для настройки прокси-сервера WinSock.You cannot use SQL ServerSQL Server Configuration Manager to configure the WinSock proxy. Чтобы настроить прокси-сервер WinSock, см. документацию по ISA Server.To configure the WinSock proxy, see your ISA Server documentation.

Node.jsNode.js

С помощью Node.js можно подключаться к SQL Server из Windows, Linux или macOS.With Node.js you can connect to SQL Server from Windows, Linux, or macOS. Корневой элемент документации Node.js можно найти здесь.The root of our Node.js documentation is here.

Драйвер подключения Node.js для SQL Server реализован в JavaScript.The Node.js connection driver for SQL Server is implemented in JavaScript. Драйвер использует протокол TDS, который поддерживают все современные версии SQL Server.The driver uses the TDS protocol, which is supported by all modern versions of SQL Server. Драйвер является проектом с открытым исходным кодом и доступен на сайте GitHub.The driver is an open-source project, available on GitHub.

Примеры кодаCode examples

ПримерExample ОписаниеDescription
Подтверждение концепции, подразумевающее подключение к SQL с помощью Node.jsProof of concept connecting to SQL using Node.js Простой исходный код для подключения к SQL Server и выполнения запроса.Bare bones source code for connecting to SQL Server, and executing a query.
База данных SQL Azure. Использование Node.js для отправки запросовAzure SQL database: Use Node.js to query Пример для Базы данных SQL Azure в облаке.Example for Azure SQL Database in the cloud.
Создание приложений Node.js для использования SQL Server в macOSCreate Node.js apps to use SQL Server on macOS Сведения о конфигурации, а также примеры кода.Configuration information, along with code examples.
 

НайтиFind What

Эти элементы управления на вкладке Найти в файлах позволяют задать строку или выражение для поиска.These controls on the Find in Files tab enable you to specify the string or expression that will be matched.

НайтиFind whatВведите текст для поиска.Type the text to search for. Диалоговое окно попытается ввести в поле поиска возможный текст поиска, используя либо текст, который был выделен курсором перед открытием диалогового окна, либо соседний текст, либо текст предыдущего поиска.The dialog box attempts to fill in a probable search text, using text selected with the cursor before opening the dialog box, or nearby text, or previously searched-for text. Можно повторно использовать одну из 20 последних строк поиска, выбрав необходимую из раскрывающегося списка.You can reuse one of the last 20 search strings by selecting it from this drop-down list.

Если необходимо использовать символы шаблонов, например звездочки () и вопросительные знаки () в строке поиска, то следует установить флажок Использовать в разделе Параметры поиска , а затем выбрать Шаблоны.If you want to use wildcards such as asterisks () and question marks () in your search string, select the Use check box under Find Options and then click Wildcards.

Чтобы средство поиска воспринимало текст в строке поиска как регулярное выражение, следует установить флажок Использовать в разделе Параметры поиска , а затем выбрать Регулярные выражения.To cause the search engine to interpret your search string as a regular expression, select the Use check box under Find Options and then click Regular expressions.

Построитель выраженийExpression BuilderЭта треугольная кнопка рядом со строкой Найти становится доступной в том случае, если установлен флажок Использовать в разделе Параметры поиска.This triangular button next to the Find what box becomes available when the Use check box is selected in Find Options. Нажмите эту кнопку для отображения списка шаблонов или регулярных выражений в зависимости от выбранных параметров Использовать .Click this button to display a list of wildcards or regular expressions, depending upon the Use option selected. Выбор любого из элементов этого списка добавляет его в строку поиска в поле Найти .Choosing any item from this list adds it to the Find what string.

Создание файла фрагмента Transact-SQLCreating a Transact-SQL Snippet File

Первая часть создания фрагмента кода Transact-SQLTransact-SQL заключается в создании XML-файла с текстом фрагмента кода.The first part of creating a Transact-SQLTransact-SQL code snippet is to create an XML file with the text of your code snippet. Файл должен иметь расширение SNIPPET и отвечать требованиям Схемы фрагментов кода.The file must have a .snippet file extension, and meet the requirements of the Code Snippets Schema. Укажите SQL в качестве языка фрагмента кода.Set the snippet language to SQL.

Можно использовать предварительно определенные фрагменты, которые поставляются вместе с SQL ServerSQL Server в качестве примеров.You can use the pre-defined snippets that ship with SQL ServerSQL Server as examples. Чтобы найти предустановленные фрагменты кода, откройте среду SQL Server Management StudioSQL Server Management Studio, а затем в меню Сервис выберите пункт Диспетчер фрагментов кода.To find the pre-defined snippets, open SQL Server Management StudioSQL Server Management Studio, select the Tools menu, and click Code Snippet Manager. Выберите SQL из списка полей Язык , путь к фрагментам Transact-SQLTransact-SQL отображается в поле Расположение .Select SQL in the Language list box, the path to the Transact-SQLTransact-SQL snippets is displayed in the Location box.

Download SSMS

SSMS 18.7.1 is the latest general availability (GA) version of SSMS. If you have a previous GA version of SSMS 18 installed, installing SSMS 18.7.1 upgrades it to 18.7.1.

Important

Beginning with SQL Server Management Studio (SSMS) 18.7, Azure Data Studio is automatically installed alongside SSMS. Users of SQL Server Management Studio are now able to benefit from the innovations and features in Azure Data Studio. Azure Data Studio is a cross-platform and open-source desktop tool for your environments, whether in the cloud, on-premises, or hybrid.

To learn more about Azure Data Studio, check out What is Azure Data Studio or the FAQ.

  • Release number: 18.7.1
  • Build number: 15.0.18358.0
  • Release date: October 27, 2020

If you have comments or suggestions, or you want to report issues, the best way to contact the SSMS team is at SQL Server user feedback.

The SSMS 18.x installation doesn’t upgrade or replace SSMS versions 17.x or earlier. SSMS 18.x installs side by side with previous versions, so both versions are available for use. However, if you have a preview version of SSMS 18.x installed, you must uninstall it before installing SSMS 18.7.1. You can see if you have the preview version by going to the Help > About window.

If a computer contains side-by-side installations of SSMS, verify you start the correct version for your specific needs. The latest version is labeled Microsoft SQL Server Management Studio 18

Note

If you are accessing this page from a non-English language version, and want to see the most up-to-date content, please visit the US-English version of the site. You can download different languages from the US-English version site by selecting .

АргументыArguments

scriptfile — указывает один или несколько файлов скриптов для открытия.scriptfile Specifies one or more script files to open. Этот параметр должен содержать полный путь к файлам.The parameter must contain the full path to the files.

projectfile — задает открываемый проект скрипта.projectfile Specifies a script project to open. Этот параметр должен содержать полный путь к файлу проекта скрипта.The parameter must contain the full path to the script project file.

solutionfile — задает открываемое решение.solutionfile Specifies a solution to open. Этот параметр должен содержать полный путь к файлу решения.The parameter must contain the full path to the solution file.

Имя сервера. Server name

Имя базы данных. Database name

Подключение с использованием аутентификации Azure Active Directory. Connect using Active Directory Authentication. Тип подключения зависит от того, включен ли параметр -U.The type of connection is determined whether -U is included.

Примечание

Проверка подлинности Active Directory — универсальная с поддержкой MFA сейчас не поддерживается.Active Directory — Universal with MFA support is not currently supported.

 — имя пользователя при подключении с использованием проверки подлинности SQL. User name when connecting with ‘SQL Authentication’

Примечание

-P был удален в SSMS версии 18.0.-P was removed in SSMS version 18.0.

Обходное решение. Попробуйте подключиться к серверу один раз с помощью пользовательского интерфейса и сохраните пароль.Workaround: Try to connect to the server once using the UI and save your password.

 — подключение с помощью проверки подлинности Windows. Connect using Windows Authentication

 — отключает отображение экрана-заставки при открытии среды SQL Server Management StudioSQL Server Management Studio. Prevents SQL Server Management StudioSQL Server Management Studio from displaying the splash screen graphic while opening. Используйте этот параметр при соединении с компьютером, где среда SQL Server Management StudioSQL Server Management Studio работает с помощью служб терминалов, через соединение с ограниченной пропускной способностью.Use this option when connecting to the computer running SQL Server Management StudioSQL Server Management Studio by means of Terminal Services over a connection with a limited bandwidth. При записи этого аргумента регистр символов не учитывается, он может быть указан до или после других аргументовThis argument is not case-sensitive and may appear before or after other arguments

? ] — записывает действия среды SQL Server Management StudioSQL Server Management Studio в указанный файл для диагностики неисправностей.?] Logs SQL Server Management StudioSQL Server Management Studio activity to the specified file for troubleshooting

 — отображает справку командной строки. Displays command-line help

УдалениеUninstall

Набор SSMS имеет общие компоненты с другими решениями, которые останутся установленными после его удаления.There are shared components that remain installed after you uninstall SSMS.

Сюда входят следующие компоненты:The shared components that remain installed are:

  • Azure Data StudioAzure Data Studio
  • Microsoft .NET Framework 4.7.2Microsoft .NET Framework 4.7.2
  • Драйвер Microsoft OLE DB для SQL ServerMicrosoft OLE DB Driver for SQL Server
  • Microsoft ODBC Driver for SQL Server версии 17Microsoft ODBC Driver 17 for SQL Server
  • Распространяемый компонент Microsoft Visual C++ 2013 (x86)Microsoft Visual C++ 2013 Redistributable (x86)
  • Распространяемый компонент Microsoft Visual C++ 2017 (x86)Microsoft Visual C++ 2017 Redistributable (x86)
  • Распространяемый компонент Microsoft Visual C++ 2017 (x64)Microsoft Visual C++ 2017 Redistributable (x64)
  • Microsoft Visual Studio Tools for Applications 2017Microsoft Visual Studio Tools for Applications 2017

Эти компоненты не удаляются, так как могут являться общими с другими продуктами.These components aren’t uninstalled because they can be shared with other products. Их удаление может нарушить работу этих продуктов.If uninstalled, you may run the risk of disabling other products.

Проверка свойств подключения с помощью таблицы окна запросовVerify your connection properties by using the query window table

Сведения о свойствах подключения приводятся под результатами запроса.You can find information about the connection properties under the results of your query. После выполнения запроса из предыдущего этапа просмотрите свойства подключения в нижней части окна запросов.After you run the previously mentioned query in the preceding step, review the connection properties at the bottom of the query window.

  • Вы можете определить, к какому серверу и какой базе данных вы подключены и под каким именем пользователя выполнен вход.You can determine which server and database you’re connected to, and the username that you use.

  • Кроме того, вы можете проверить длительность запроса и число строк, возвращенных предыдущим запросом.You can also view the query duration and the number of rows that are returned by the previously executed query.

    Примечание

    На рисунке результаты отображаются в виде текста.In the image, the results are displayed in Text View.

Разрешение дополнительных соединенийAuthorizing Additional Connections

Теперь, после подключения к SQL ServerSQL Server в качестве администратора, одной из первых задач будет обеспечить возможность подключения других пользователей.Now that you have connected to SQL ServerSQL Server as an administrator, one of your first tasks is to authorize other users to connect. Это делается посредством создания имени входа и предоставления ему разрешения на доступ к базе данных в качестве пользователя.You do this by creating a login and authorizing that login to access a database as a user. Имена входа могут быть или именами входа для проверки подлинности Windows, использующей учетные данные Windows, или именами входа для проверки подлинности SQL Server, который хранит учетные данные в SQL ServerSQL Server и не зависит от учетных данных Windows.Logins can be either Windows Authentication logins, which use credentials from Windows, or SQL Server Authentication logins, which store the authentication information in SQL ServerSQL Server and are independent of your Windows credentials. По возможности используйте проверку подлинности Windows.Use Windows Authentication whenever possible.

Совет

В большинстве организаций пользователи входят в домены, и используется проверка подлинности Windows.Most organizations have domain users and will use Windows Authentication. Вы можете поэкспериментировать самостоятельно, создав дополнительных локальных пользователей на своем компьютере.You can experiment on your own, by creating additional local users on your computer. Локальные пользователи будут проходить проверку подлинности на вашем компьютере, поэтому доменом является его имя.Local users will be authenticated by your computer, so the domain is the computer name. Например, если ваш компьютер имеет имя и вы создали пользователя с именем , то в Windows этот пользователь указывается как .For example if your computer is named and you create a user named , then the Windows description of the user is .

Создание имени входа для проверки подлинности WindowsCreate a Windows Authentication login
  1. В предыдущей задаче было установлено соединение с компонентом Компонент Database EngineDatabase Engine с помощью среды Среда Management StudioManagement Studio.In the previous task, you connected to the Компонент Database EngineDatabase Engine using Среда Management StudioManagement Studio. В обозревателе объектов разверните экземпляр своего сервера, затем узел Безопасность , щелкните правой кнопкой мыши Имена входа и выберите пункт Создать имя входа.In Object Explorer, expand your server instance, expand Security , right-click Logins , and then click New Login. Откроется диалоговое окно Создание имени входа .The Login — New dialog box appears.

  2. На странице Общие в поле Имя входа введите имя входа Windows в следующем формате: On the General page, in the Login name box, type a Windows login in the format:

В поле База данных по умолчанию выберите AdventureWorks2012AdventureWorks2012 , если она доступна.In the Default database box, select AdventureWorks2012AdventureWorks2012 if available. В противном случае выберите базу данных master.Otherwise select master.

На странице Роли сервера щелкните sysadmin , если новое имя входа принадлежит администратору, иначе оставьте пустым.On the Server Roles page, if the new login is to be an administrator, click sysadmin , otherwise leave this blank.

На странице Сопоставление пользователей выберите Схема для базы данных AdventureWorks2012AdventureWorks2012 , если она доступна.On the User Mapping page, select Map for the AdventureWorks2012AdventureWorks2012 database if it is available. В противном случае выберите базу данных master.Otherwise select master

Обратите внимание, что в поле Пользователь прописано имя входа.Note that the User box is populated with the login. После закрытия диалогового окна в базе данных будет создан пользователь.When closed, the dialog box will create this user in the database.

В поле Схема по умолчанию введите dbo , чтобы сопоставить имя входа со схемой владельца базы данных.In the Default Schema box, type dbo to map the login to the database owner schema.

Подтвердите настройки по умолчанию для полей Защищаемые объекты и Состояние , и нажмите кнопку ОК , чтобы создать имя входа.Accept the default settings for the Securables and Status boxes and click OK to create the login.

Важно!

Это базовые сведения, позволяющие начать работу.This is basic information to get you started. SQL ServerSQL Server предоставляет безопасную среду; безопасность безусловно важна при выполнении операций с базой данных.provides a rich security environment, and security is obviously an important aspect of database operations.

Стихи — Стихи слагать не мой удел дума о будущем

Подключение к экземпляру SQL ServerConnect to a SQL Server instance

Примечание

В декабре 2021 г. выпуски SSMS до версии 18.6 перестанут использовать многофакторную проверку подлинности через Azure Active Directory.In December 2021, releases of SSMS prior to 18.6 will no longer authenticate through Azure Active Directory with MFA.

Чтобы и дальше использовать проверку подлинности Azure Active Directory с MFA, установите SSMS 18.6 или более поздней версии.To continue utilizing Azure Active Directory authentication with MFA, you need SSMS 18.6 or later.

  1. Запустите среду SQL Server Management Studio.Start SQL Server Management Studio. При первом запуске SSMS откроется окно Подключение к серверу.The first time you run SSMS, the Connect to Server window opens. Если этого не происходит, вы можете открыть его вручную, последовательно выбрав Обозреватель объектов > Подключить > Ядро СУБД.If it doesn’t open, you can open it manually by selecting Object Explorer > Connect > Database Engine.

  2. В окне Подключение к серверу сделайте следующее по списку ниже.In the Connect to Server window, follow the list below:

    • В поле Тип сервера выберите Ядро СУБД (обычно это параметр по умолчанию).For Server type, select Database Engine (usually the default option).
    • В поле Имя сервера введите имя своего экземпляра SQL Server.For Server name, enter the name of your SQL Server instance. (В этой статье используется имя экземпляра SQL2016ST и имя узла NODE5: NODE5\SQL2016ST.) Если вы не знаете, как определить имя экземпляра SQL Server, см. раздел .(This article uses the instance name SQL2016ST on the hostname NODE5 .) If you’re unsure how to determine your SQL Server instance name, see .
    • В поле Проверка подлинности выберите Проверка подлинности Windows.For Authentication, select Windows Authentication. В этой статье используется проверка подлинности Windows, но поддерживаются также и учетные данные SQL Server.This article uses Windows Authentication, but SQL Server login is also supported. При выборе Учетных данных SQL отобразится запрос на ввод имени пользователя и пароля.If you select SQL Login, you’re prompted for a username and password. Дополнительные сведения о типах проверки подлинности см. в разделе Подключение к серверу (ядро СУБД).For more information about authentication types, see Connect to the server (database engine).

    Вы также можете изменить дополнительные параметры подключения, выбрав Параметры.You can also modify additional connection options by selecting Options. Примеры параметров подключения: база данных, к которой вы подключаетесь, время ожидания подключения и сетевой протокол.Examples of connection options are the database you’re connecting to, the connection timeout value, and the network protocol. Эта статья использует во всех параметрах значения по умолчанию.This article uses the default values for all the options.

  3. После заполнения всех полей выберите Подключить.After you’ve completed all the fields, select Connect.

Примеры успешных соединенийExamples of successful connections

Чтобы проверить, успешно ли установлено подключение к серверу SQL Server, просмотрите объекты в обозревателе объектов.To verify that your SQL Server connection succeeded, expand and explore the objects within Object Explorer. Эти объекты будут различаться в зависимости от типа сервера, к которому установлено подключение.These objects are different depending on the type of server you choose to connect.

  • Подключение к локальному серверу SQL Server — NODE5\SQL2016ST: Connecting to an on-premises SQL server — in this case NODE5\SQL2016ST:

  • Подключение к базе данных SQL Azure — msftestserver.database.windows.net: Connecting to SQL Azure DB — in this case msftestserver.database.windows.net:

Примечание

Ранее в этой статье вы подключились к локальному серверу SQL Server с помощью проверки подлинности Windows, но для базы данных SQL Azure этот способ не поддерживается.In this article, you previously used Windows Authentication to connect to your on-premises SQL server, but this method is not supported for SQL Azure DB. На этом рисунке показано подключение к базе данных SQL Azure с помощью проверки подлинности SQL.As such, this image shows using SQL Authentication to connect to the SQL Azure DB. Дополнительные сведения см. в разделах, посвященных локальной проверке подлинности SQL и .For more information, see SQL on-premises authentication and .

Supported SQL offerings

  • This version of SSMS works with all supported versions of SQL Server 2008 — SQL Server 2019 (15.x) and provides the greatest level of support for working with the latest cloud features in Azure SQL Database and Azure Synapse Analytics.
  • Additionally, SSMS 18.x can be installed side by side with SSMS 17.x, SSMS 16.x, or SQL Server 2014 SSMS and earlier.
  • SQL Server Integration Services (SSIS) — SSMS version 17.x or later doesn’t support connecting to the legacy SQL Server Integration Services service. To connect to an earlier version of the legacy Integration Services, use the version of SSMS aligned with the version of SQL Server. For example, use SSMS 16.x to connect to the legacy SQL Server 2016 Integration Services service. SSMS 17.x and SSMS 16.x can be installed side by side on the same computer. Since the release of SQL Server 2012, the SSIS Catalog database, SSISDB, is the recommended way to store, manage, run, and monitor Integration Services packages. For details, see SSIS Catalog.

Джесси Липскин

Вместо того, чтобы искать дом своей мечты, Джесси решила построить его самостоятельно. Пролистывая eBay, она влюбилась в  автобус GMC 1966 года выпуска. Джесси потратила три года, чтобы превратить старую рухлядь в бесподобный дом на колесах. Самым сложным этапом, был поиск подходящих людей, для завершения проекта. 

Более подробная информация: Instagram

Фотография

Добавить комментарий

Ваш адрес email не будет опубликован. Обязательные поля помечены *

Adblock
detector