MS-Access / Getting Started

Linking to SQL Server Databases

In a system where you store your data solely in Access tables, the Access Database Engine supplies all data retrieval and management functions and handles security, data validation, and enforcement of referential integrity.

In a system where Access acts as a front end to client/server data, the server handles the data management functions. It's responsible for retrieving, protecting, and updating data on the back-end database server. In this scenario, the local copy of Access is responsible only for sending requests and getting either data or pointers to data back from the database server. If you're creating an application in which Access acts as a front end, capitalizing on the strengths of both Access and the server can be a challenging endeavor.

You might ask why you would want to convert your database to a client/server application. The reasons include the following:

  • Greater control over data integrity
  • Increased control over data security
  • Increased fault tolerance
  • Reduced network traffic
  • Improved performance
  • Centralized control and management of data

Scenarios in which you may need to upsize include the following:

  • Large number of simultaneous users (more than 10-15)
  • Large volume of data (tables with more than approximately 100,000 rows)
  • Increased need for security (payroll data and such)

Link to SQL Server Data

If you store your data in SQL Server, you will need to link to it from your Access database. The steps that follow show you how to link from an Access database to a table stored on a SQL Server:

  1. Select ODBC Database from the Import & Link group on the External Data tab of the Ribbon. The Get External Data - ODBC Database dialog appears.
  2. Select Link to the data source by creating a linked table and click OK. The Select Data Source dialog appears.
  3. Select the Machine Data Source tab. The dialog appears.
  4. Click New. A warning may appear indicating that you are unable to create System DSNs. If the warning appears, click OK to dismiss the dialog. The Create New Data Source Wizard appears.
  5. Click Next. The wizard appears.
  6. Select SQL Server or SQL Server Native Client 10.0 (depending on which version of SQL Server you are accessing), and then click Next.
  7. Click Finish to launch the Create a New Data Source to SQL Server Wizard.
  8. Supply a name and optional description for the data source.
  9. Designate the name of the SQL Server you want to connect to. (You might need to contact your system administrator to obtain this information.)
  10. Click Next. The wizard appears.
  11. Indicate the type of security you will use to log on to the server. (Again, you might need to contact your system administrator for this information.)
  12. Click Next. The wizard appears.
  13. Change the default database to point at the SQL Server database that you want to link to.
  14. Click Test Data Source to test your connection to the SQL Server database. A dialog appears confirming that the test was successful.
  15. Click OK to close the dialog, and OK again to close the wizard. Your data source appears in the list of available data sources.
  16. Click OK to select the new data source and begin the process of linking to the tables within it. The Link Tables dialog appears.
  17. Select the tables you want to link to and click OK. The process completes and the tables appear in the Navigation Pane with globes, indicating that they are using ODBC to connect to the SQL Server. You can now treat the tables like any other linked tables.
[Previous] [Contents] [Next]