ODBC TUTORIAL

Connect to MongoDB database from SSLS

Updated: 31 Jul 2024

Introduction

Progress DataDirect’s MongoDB ODBC Driver offers a high-performing, secure and reliable connectivity solution, for ODBC applications to access MongoDB data. If you want to connect MongoDB data from SSLS, Progress DataDirect has you covered. This tutorial will teach you how to configure the DataDirect MongoDB driver within SSMS (SQL Server Management Studio). These steps can also be used to configure any ODBC connection. 

 

SQL Server Management Studio is an ideal environment for managing the infrastructure of the SQL Server database and SQL Server itself. With SSMS, you can easily connect to your SQL Server instance, configure, and monitor database objects, and execute queries. Besides this, there is a possibility to create an ODBC connection to external data from SSMS. 

 

Thus, you can work with other databases and clouds used by your applications. 

 

In this article, we will describe a step-by-step procedure for establishing a connection to MongoDB from SSMS using our ODBC Driver for MongoDB 

 

Configure Connection to MongoDB ODBC Driver Using the ODBC Administrator

1. Download and install the Progress DataDirect ODBC driver using the 15-day trial software. In this tutorial, we are connecting to MongoDB Database. 

2. After the DataDirect MongoDB ODBC driver has been installed, open ODBC Administrator to configure the connection. Go to System DSN and click on Add.    

 

 

 

3. Choose the “DataDirect X.X MongoDB Wire Protocol” and click on “Finish.” 

 

Graphical user interface, application, Word

Description automatically generated

 

4. The ODBC MongoDB configuration manager will open in the default browser. 

 

A screenshot of a computer

Description automatically generated

 

Enter your credentials, click on “Save” and then click on “Test Connect.” 

 

5. The MongoDB Logon screen will pop up. Provide logon credentials and click on “OK.” 

 

 

 

 

6. A dialog box will appear. This dialogue box will show the connection status (Pass/Fail) and previews the data. 

 

 

Configure the DataDirect ODBC MongoDB Driver with Microsoft SQL Server Management Studio

1. Launch SQL Server Management Studio.

 

2. Navigate to Server Objects > Linked Servers > Providers > MSDASQL > and confirm that the Allow inprocess and Non transacted updates options are Enabled. 

 

Graphical user interface, application

Description automatically generated

 

3. In the object explorer navigate to Server Objects > Linked Servers. Right-click and select New Linked Server. 


Graphical user interface, application

Description automatically generated 

 

4. Fill in all the details. 

  1. Name your linked server. 

  1. Check the Server type as another data source. 

  1. Select provider as Microsoft OLE DB Provider for ODBC Drivers from the drop-down menu.  

  1. Enter the Product name as DataDirect.  

  1. Enter the Data Source name created in the ODBC configuration process.  

  2.  

 

 

5. Click on the Security page and select “Be made using this security context”. Then enter your MongoDB username and password. 

 

A screenshot of a computer

Description automatically generated 

 

6. Click on the Server Options tab and ensure that they match the following options shown in the following screen capture. 

 

Graphical user interface, application

Description automatically generated 

 

7. That’s it! You’re all done! Now you can find MongoDB in the provider's list. Navigate to MongoDB > Catalogs > default > Tables. You should see your tables now and be able to query your MongoDB data from the linked server 

 

 

Conclusion

Get started today with a free 15-day trial of Progress DataDirect MongoDB ODBC drivers, and connect to Microsoft SQL Server Management Studio. 

Contact Us for assistance with any questions you may have, and we will be happy to help!  

 

Connect any application to any data source anywhere

Explore all DataDirect Connectors

Need additional help with your product?

Get Customer Support