Datagrip连接SQLServer Connecting DataGrip to MS SQL Server

时间:2022-09-02 17:26:55

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:

Datagrip连接SQLServer  Connecting DataGrip to MS SQL Server

TCP/IP connections need to be enabled:

Datagrip连接SQLServer  Connecting DataGrip to MS SQL Server

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

Datagrip连接SQLServer  Connecting DataGrip to MS SQL Server

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.

Datagrip连接SQLServer  Connecting DataGrip to MS SQL Server

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

Datagrip连接SQLServer  Connecting DataGrip to MS SQL Server

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.

Datagrip连接SQLServer  Connecting DataGrip to MS SQL Server

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.

Datagrip连接SQLServer  Connecting DataGrip to MS SQL Server

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

Datagrip连接SQLServer  Connecting DataGrip to MS SQL Server

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.

Datagrip连接SQLServer  Connecting DataGrip to MS SQL Server

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:

Datagrip连接SQLServer  Connecting DataGrip to MS SQL Server

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

Datagrip连接SQLServer  Connecting DataGrip to MS SQL Server

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

Datagrip连接SQLServer  Connecting DataGrip to MS SQL Server

And here’s how it looks in DataGrip:

Datagrip连接SQLServer  Connecting DataGrip to MS SQL Server

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

Datagrip连接SQLServer Connecting DataGrip to MS SQL Server的更多相关文章

  1. 怎样将DataGrip连接到MS SQL Server?

    DataGrip支持几乎所有主流的关系数据库产品,如DB2.Derby.H2.MySQL.Oracle.PostgreSQL.SQL Server.Sqllite及Sybase等,并且提供了简单易用的 ...

  2. java连接ms sql server各类问题解析

    首先先来说下使用微软自己开发的架包进行ms sql server数据库的连接时,sql 2000与sql 2005的连接方式略有不同: 1.首先驱动不一样,sql 2000的连接驱动包有三个,分别是: ...

  3. .net core连接Liunx上MS SQL Server

    场景 由于业务要求,需要对甲方的一个在SQL Server上的财务表进行插入操作.研究了半天,因为一个小问题折腾了很久. 过程 .net core端: 1. 利用EF,就需要的导入相关的Nuget包, ...

  4. elasticsearch与ms sql server数据同步

    MS SQL Server Download Elasticsearch Install Elasticsearch Follow instructions on https://www.elasti ...

  5. Docker-compose搭建ELK环境并同步MS SQL Server数据

    前言 本文作为学习记录,供大家参考:一次使用阿里云(Aliyun)1核2G centos7.5 云主机搭建Docker下的ELK环境,并导入MS SQL Server的商品数据以供Kibana展示的配 ...

  6. [MS SQL Server]SQL Server如何开启远程访问

    在日常工作中,经常需要连接到远程的MS SQL Server数据库中.当然也经常会出现下面的连接错误. 解决方法: 1. 设置数据库允许远程连接,数据库实例名-->右键--->属性---C ...

  7. Linux下使用FreeTDS访问MS SQL Server 2005数据库(包含C测试源码)

    Linux下使用FreeTDS访问MS SQL Server 2005数据库(包含C测试源码) http://blog.csdn.net/helonsy/article/details/7207497 ...

  8. 在英文版操作系统中安装的MS SQL server,中文字段无法匹配

    在英文版的操作系统中安装的MS SQL server,会出现中文字段无法被匹配到.其原因在于英文环境下安装的MS SQL server的排序规则不包括中文. 所以解决办法就是更改MS SQL serv ...

  9. MS SQL Server2014链接MS SQL Server 2000

    开发与企业应用中,好几个版本SQL Server相互链接.分布式读取与存储,需要实现sp_addlinkedserver.SQL Server 2000, SQL Server 2008, SQL S ...

随机推荐

  1. JAVA 取得当前目录的路径/Servlet/class/文件路径/web路径/url地址

    在写java程序时不可避免要获取文件的路径...总结一下,遗漏的随时补上 1.可以在servlet的init方法里 String path = getServletContext().getRealP ...

  2. 深入体验bash on windows,在windows上搭建原生的linux开发环境,酷!

    今年微软Build 2016大会最让开发人员兴奋的消息之一,就是在Windows上可以原生运行Linux bash,对开发人员来说,这是一个喜闻乐见的消息. 1 安装 你必须安装开发者预览版本,才能使 ...

  3. Java垃圾回收小结

    一.如何确定某个对象是“垃圾”? 首先要搞清一个最基本的问题:如果确定某个对象是“垃圾”?既然垃圾收集器的任务是回收垃圾对象所占的空间供新的对象使用,那么垃圾收集器如何确定某个对象是“垃圾”?—即通过 ...

  4. HTML5的manifest缓存

    要使用manifest缓存,我们首先需要写一个manifest文件.这个文件有严格的格式要求,下面是个例子CACHE MANIFEST#我是注释,这个文件名叫test.manifestCACHE:/t ...

  5. MongoDB库设计原则及实践

    MongoDB数据模型选择• CAP定理(Consistency ,Availability 和Partition Tolerance )– Consistency(一致性):数据一致更新,所有数据变 ...

  6. Autodesk 开源 3D 打印机

    Autodesk 开源 3D 打印机 Autodesk在知识共享-署名-相同方式共享许可证下公开了其3D打印机Ember的树脂.机械设计.电路图纸的细节,在GNU GPL许可证下公开了固件.打印机运行 ...

  7. PAT (Advanced Level) 1096. Consecutive Factors (20)

    如果是素数直接输出1与素数,否则枚举长度和起始数即可. #include<cstdio> #include<cstring> #include<cmath> #in ...

  8. Docker下搭建Jenkins构建环境

    首先需要搭建好docker环境的linux系统,这个教程多如牛毛,在此不再赘述. 然后编写一个dockerfile来生成一个镜像,dockerfile其实就是一系列命令的集合,有点像windows的批 ...

  9. 连接Redis后执行命令错误 MISCONF Redis is configured to save RDB snapshots

    今天在redis中执行setrange name 1 chun 命令时报了如下错误提示: (error) MISCONF Redis is configured to save RDB snapsho ...

  10. FreeRTOS

    一.内核配置 1.configUSE_PREEMPTION 设置为1,使用抢先式内核:设置为0,为合作轮转内核. 2.configCPU_CLOCK_HZ 内部处理器执行的频率.这个值需要正确配置外围 ...