Part I: Setting Up the ODBC Data Source

Before you can use the ODBC API, you must set up an ODBC data source. In this exercise, you will interact with the Microsoft Access database NORTHWIND.MDB, which ships with Visual Basic and which is included on the companion CD-ROM.

Establishing the data source is not a development tool function, but rather an operating system function. Setup is accomplished using the ODBC Data Source Administrator utility found in Microsoft Windows.

Step 1

In the Control Panel, locate an icon labeled ODBC. Double-click this icon to start the ODBC Data Source Administrator.

Step 2

In order to create a new data source, click the System DSN tab and then click the Add button.

Step 3

The Create New Data Source dialog box will appear, listing all the ODBC drivers available on your machine. For this exercise, you will need the Microsoft Access driver. Choose this driver from the list, and click Finish.

Step 4

When the ODBC Setup dialog box appears, you can define the new data source. First, you must provide a name. This can be any name, but for this exercise, type NorthWind.

Next, click the Select button and navigate the file system until you find the NORTHWIND.MDB file. Select this database file.

Click the OK button, and back out of the ODBC Data Source Administrator. You have now defined the data source.



Programming Active Server Pages
Programming Active Server Pages (Microsoft Programming Series)
ISBN: 1572317000
EAN: 2147483647
Year: 1996
Pages: 84

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net