Connecting DataGrip to MS SQL Server

Posted on June 21, 2016 by Maksim Sobolevskiy

Some specific needs of SQL developers like connecting to SQL Server from OSX and even using Windows authentication can be covered by DataGrip. Since releasing DataGrip, we’ve received lots of comments about connecting to SQL Server. It appears it’s not straightforward as with other databases, requiring a couple of extra steps beforehand. Here is a small guide describing the main problems you may face and how to solve them.

First, ensure that important options in SQL Server Configuration Manager are configured correctly. Make sure the SQL Server Browser is running:

TCP/IP connections need to be enabled:

To know the port for the connection just click on TCP/IP. In our case, it’s default port 1433.

If you end up changing anything, restart the server. For most situations, this will resolve connection problems, your server will accept remote connections and you are ready to go. If you still have problems, it could be that TCP port needs to be adjusted or the remote connection to SQL server needs to be enabled in its settings. This tutorial will walk you through it, but we’ll also describe the process here.

Invoke Database View by pressing Alt/Cmd+1 and create a new data source with the appropriate driver. If you use a Microsoft driver, note that it supports SQL Server 2008 and later versions. Here we’ll assume it’s the jTds driver.

If you have no driver, download it by clicking the link.

Then enter the host name, the instance name and the credentials. Remember that DataGrip offers completion for host, instance and database names (Ctrl/Cmd+Space), but the name of the database is optional. For those who are used to the SSMS interface, let’s compare the connection windows.

If the port number conflicts with the instance name, in the jTds driver, the instance name will take precedence over the port number, while the opposite will happen in the Microsoft driver. To avoid confusion, simply remove the port number. If you strongly wish to specify the port number, click the Auto-set button (located to the right of the Instance field) to have the port number set automatically. But remember that the port number can be changed in case you restart the server.

If you need to use Windows authentication, only Microsoft driver will let you do it.

The other way to connect to the server with Windows authentication is to use domain authentication of jTds driver, which lets you connect from any other machine. What is notable, it works on any OS. To do this, go to the Advanced tab of data source properties, set USENTLMV2 to true and specify the domain name in the DOMAIN field.

Then enter your Windows credentials in user/password fields and click Test Connection.

If you want to check which particular databases or schemas are shown in the database view, go to the Schemas tab in Data source properties:

In case you are already using DataGrip 2016.2 EAP, use More Schemas… in the database view:

All selected databases will appear in the database view. This is how it looks in SQL Server Management Studio:

And here’s how it looks in DataGrip:

That’s it! If you are experiencing any other problems, please tweet @ us or create an issue in our youtrack.

Your DataGrip Team

The Drive to Develop

最新文章

  1. WEB前端--背景相关知识点总结
  2. web端功能测试总结(一)
  3. NEERC2014 Eastern subregional
  4. day10---multiprocess 多进程
  5. PHP知识库图谱汇总(完善中)
  6. Python绑定方法,未绑定方法,类方法,实例方法,静态方法
  7. HTML5离线应用无法更新的定位与解决
  8. UML:包图
  9. 【转载】C++ inline 函数
  10. 分享 - Social.framework
  11. U盘启动盘安装Windows10操作系统详解
  12. gevent多协程运用
  13. Visual Studio 2015开发Qt项目实战经验分享(附项目示例源码)
  14. python测试开发django-18.admin后台中文版
  15. VB将MSHFlexGrid数据导出到Excel文件通用功能
  16. java基础64 JavaScript中的Arrays数组对象和prototype原型属性(网页知识)
  17. eclipse tomcat timeout时间设置
  18. FAQ:如何修改领域模型?
  19. 3.3.2线程安全的HashMap
  20. 6、Semantic-UI之动画按钮样式

热门文章

  1. 基于Python Pillow库生成随机验证码
  2. 转 Multiple outputs from T4 made easy t4生成多文件
  3. JS膏集04
  4. Ajax发送请求,并接受字符串
  5. 【小程序】小程序开发自定义组件的步骤>>>>>>>>>小程序开发过程中报错:jsEnginScriptError
  6. 【jvm】windows下查看java进程下多线程的相关信息
  7. poi 升级至4.x 的问题总结(POI Excel 单元格内容类型判断并取值)
  8. [Web 前端] VML、SVG、Canvas简介
  9. 为Ubuntu新创建用户创建默认.bashrc并自动加载
  10. Centos7 设置、查看、添加、删除服务的开机启动项