Database Toolbox User's Guide
  Go to function:
    Search    Help Desk 

Setting Up a Data Source

Note:
If you are using a JDBC driver, you do not need to set up a data source. Instead you provide the JDBC driver with the necessary database location information when you connect to the database using the database command.

To use the Database Toolbox with your database and an ODBC driver, you need to set up a data source. A data source consists of data that you want the toolbox to access and information on how to find the data, such as driver, directory, server, or network names. You assign a name to each data source.

You can set up local data sources for databases that reside on your PC, or remote data sources for databases that reside on systems that are networked to your PC. The data source setup procedures for local and remote data sources differ slightly - use the appropriate instructions for your database.

Setting Up a Local Data Source

Follow this procedure to set up a local data source. This procedure uses as an example, the Microsoft ODBC driver Version 3.40 and Microsoft Access Version 7.00 for Windows NT. If you are using a different configuration, you will have to modify the instructions slightly.

If you have Microsoft Access installed and want to use the tutorial in Chapter 3 as written, follow information labeled "For the tutorial" when you set up the data source. The tutorial uses the data source, SampleDB, which you set up here. SampleDB uses the Microsoft Access sample database called Northwind.

   1.
From the Windows Start menu, select Control Panel from the Settings menu.
   2.
Double-click ODBC.
The ODBC Data Source Administrator dialog box appears, listing any existing data sources.
   3.
Click Add. A list of installed ODBC drivers appears in the Create New Data Source dialog box.
   4.
Select the ODBC driver that the local data source you are creating will use and click Finish.
The ODBC Setup dialog box appears for the driver you selected. Note that the dialog box for your driver might be different from the one shown here.


   5.
Provide a Data Source Name and Description.
For the tutorial, type SampleDB as the data source name, and for the description, type For the Database Toolbox tutorial.
Note that for some databases, the ODBC Setup dialog box requires you to provide additional information.
   6.
Select the database that this data source will use. Note that for some drivers, you skip this step.
  1. In the ODBC Setup dialog box, click Select.

    The Select Database dialog box appears.


  2. Find and select the database you want to use.

    For the tutorial, select Northwind.mdb in the msoffice\Access\Samples directory.

  3. Click OK to close the Select Database dialog box.
   7.
In the ODBC Setup dialog box, click OK.
   8.
Click OK to close the ODBC Data Source Administrator dialog box.

Setting Up a Remote Data Source

Follow this procedure to set up a data source that resides on a remote system to which your PC has network access. This procedure uses the Microsoft ODBC driver Version 3.40 and Microsoft Access Version 7.00 for Windows NT that is installed on a network server. If you are using a different configuration, you will have to modify the instructions slightly.

If you have Microsoft Access installed on a networked server and want to use the tutorial in Chapter 3 as written, follow information labeled "For the tutorial" when you set up the data source. The tutorial uses the data source, SampleDB, which you set up here. SampleDB uses the Microsoft Access sample database called Northwind.

   1.
From the Windows Start menu, select Control Panel from the Settings menu.
   2.
Double-click ODBC.
The ODBC Data Source Administrator dialog box appears.
   3.
Click the System DSN tab.
A list of existing system data sources appears.
   4.
Click Add. A list of installed ODBC drivers appears in the Create New Data Source dialog box.
   5.
Select the ODBC driver that the local data source you are creating will use and click Finish.
The ODBC Setup dialog box appears for the driver you selected. Note that the dialog box for your driver might be different from the one shown here.


   6.
Provide a Data Source Name and Description.
For the tutorial, type SampleDB - Remote as the data source name, and for the description, type For the Database Toolbox tutorial.
Note that for some databases, the ODBC Setup dialog box requires you to provide additional information.
   7.
Select the database that this data source will use. Note that for some drivers, you skip this step.
  1. In the ODBC Setup dialog box, click Select.

    The Select Database dialog box appears.


  2. Click Network.

    The Map Network Drive dialog box appears.


  3. Find and select the database you want to use. For the tutorial, select Northwind.mdb in the msoffice\Access\Samples directory.

    In this example, the database is in SERVERS\APPLICATIONS\Applications. After selecting this directory, the Map Network Drive dialog box closes automatically and you continue locating the file in the Select Database dialog box.

  4. Click OK to close the Select Database dialog box.
   8.
In the ODBC Setup dialog box, click OK.
   9.
Click OK to close the ODBC Data Source Administrator dialog box.


[ Previous | Help Desk | Next ]