Connecting To An ODBC Database

Top  Previous  Next

Setting up a connection between CaveBase and an ODBC database is a bit complicated so here is a set of step-by-step procedures. I have chosen to use Microsoft Access for the example, since is one of the more common databases. However, the same procedure will work for other types of databases.

 

I. Setting Up The ODBC Data Source Administrator. The first step in the process is configuring the ODBC Data Data Source Administrator.

 

1. Run The ODBC Data Source Administrator. In Windows 98/Me, open "My Computer" and select the "Windows Control Panel." Select the "ODBC Data Sources" applet. Under Windows 2000 or XP, click the “Start Button”, select “Settings”, and then click “Control Panel.” Double-click Administrative Tools, and then double-click “Data Sources (ODBC).”

 

2. Creating A New Data Source Name (DNS). The next step is to create a new Data Source Name or open an exiting Database for your database. Select the "User DSN" page. Press the "Add" button. You will be presented with a list of driver that can access various kinds of databases. Choose a driver that matches the type of database you want to use. For example, if you want to use an MS-Access database, select the Access driver.

 

(If you don't find the proper driver in the list, you may have to install it. Generally speaking, the Access driver is automatically installed with Windows even if you don't have Access installed on your system.)

 

3. Select A Databases File. After you have selected a driver, you will be presented with a page that allows you to configure the data source. Enter a name for the data source and then press the "Select" button. Find the database you want to connect to (for Access, an *.MDB file) and then select OK.

 

4. Setting A Password. Generally speaking, you don’t need a username or password for your database. However, if your computer is configured to have multiple users and there are security policies in place, you may need to set a username and password for your alias. Each type of database has its own way of setting this information. For example, with an Access database, you press the “Advanced” button and enter the username and password.  (Refer to Windows Help or the Windows Resource Kit for further information.)

 

5. Finish Up. Select OK again to finish up. Your new data source should appear in the list of "User Data sourses." Close ODBC Data Source Administrator.

 

The BDE Administrator. You can also configure Alias and ODBC Drivers using the “BDE Administrator”. For more information on the BDE Administrator, click here.

II. Connecting With Cavebase. The final step is to open your newly created with CaveBase. You just run CaveBase and follow the alias opening instructions found here. You should see your newly created alias in the list of available alias on your machine. Select one of the Aliases and the corresponding Table and click on OK. The database should now be open and be accessible.