0

I installed the CData ODBC Driver for MongoDB to make the application that can access SQL Server connect to mongodb. According to the official document,I have configured the system DSN. Then I modified the config file 'CData.ODBC.MongoDB.Remoting.ini' config file screenshot:-

enter image description here

,in which the users and passwords was the same as what I typed in DSN. I started CData.ODBC.MongoDB.Remoting.exe and the console printed

Test connection successful. CData ODBC Driver For MongoDB 2015 remoting server starts.Local port :3309.

But when I created a linked server from SQL Server Management Studio linked server info

enter image description here

,it showed that the user 'noobwulei' login failed. I am searching for a long time on net. But no use. Please help or try to give some ideas how to achieve this.

Saqib Ali
  • 3,953
  • 10
  • 55
  • 100
GarenPig
  • 1
  • 1

1 Answers1

0

Based on the console output, looks like the remoting service isn't running on the expected port:

... Local port :3309.

According to the Help documentation (http://cdn.cdata.com/help/DGB/odbc/pg_cli.htm) the executable runs the MySQL daemon by default.

In order to run the TDS daemon, you will need to run the executable from the command line and pass TDS as the protocol option (-t):

\> CData.ODBC.MongoDB.Remoting.exe -t TDS
Jerod Johnson
  • 764
  • 7
  • 15
  • Thank you for your answer!.It does work.I thought the port 3309 was which the application CData.ODBC.MongoDB.Remoting.exe run on – GarenPig Feb 22 '17 at 03:34
  • I connected successfully.But I got a new problem .There is no data returned and no error after I executed the query – GarenPig Feb 22 '17 at 03:41
  • It sounds like you've got a different question now. I'd suggest starting a new StackOverflow question or reaching out directly to the CData Software support team (support AT cdata DOT com). – Jerod Johnson Feb 22 '17 at 17:19