Skip to content

Creating a system data source name (DSN)

After creating your database, you must associate it with your system.

To create a system DSN in SQL Server

1. In Windows, open Control Panel.

2. Select Administrative Tools.

3. Select ODBC Data Source Administrator.

4. Select the System DSN tab.

System DSN

5. Click Add button.

6. In the Create New Data Source dialog, select "SQL Server" from the driver list. Click the Finish button.

Create new data source

7. In the Create a New Data Source to SQL Server dialog, enter the data source Name and the Description, such as sqlodbc. Select a server from the "Which SQL Server do you want to connect to?" drop-down menu. Click the Next button.

8. Check "With SQL Server authentication using a login ID and password entered by the user" and "Connect to SQL Server to obtain default settings for the additional configuration options". Enter the User name and Password (login to the database). Click the Next button.

SQL username and password

9. Check "Change the default Database" and choose the database you created in the SQL Server.

10. Next -> ... ->Finish.

11. Click the Test button to test whether it connects successfully.

To create a system DSN in MySQL

create system DSN for MySQL

Steps 1-5. Same as above.

6. In the Create New Data Source dialog, select the appropriate MySQL Server driver from the list. If the driver doesn't exist, you must install it first. You can download it from http://dev.mysql.com/downloads/connector/odbc/5.1.html#win32. When you have downloaded and selected the appropriate server driver, click Finish.

7. Enter the Data Source Name, such as mysqlodbc.

8. Enter a Description of this data source.

9. Enter the Server. If the server is on a local machine, use "localhost".

10. Enter the User name by which you log on to the database. Such as: root.

11. Enter the Password of the user.

12. Select the database from the drop-down menu to connect to.

13. Test whether the database connects successfully.

To create a system DSN in Microsoft Access

create DSN in MS Access

Steps 1-5. Same as above.

6. In the Create New Data Source dialog, select "Microsoft Access Driver (*.mdb)" from the driver list. Click the Finish button.

7. Enter the Data Source Name. Such as accessodbc.

8. Click the "Select" button to select a local access database.