Creating the Access Database

Although you could certainly create the database for this exercise manually, the number of entries required for a complete online store makes manual database construction unreasonable for this project. Instead, copy the bookstor.mdb database from the project3 folder on the companion CD and store it in the bookdata\project3 folder you created earlier. The database used with this project is a modified version of the biblio.mdb database that ships with Microsoft Visual Basic.

This project uses several structured query language (SQL) queries to implement the search engine for the bookstore. These SQL queries perform multiple table joins and are dependent on the relationships in the database. For this reason, you must have a firm understanding of several tables for this project. The structures of the database tables, which are already implemented in bookstor.mdb, are shown in Tables 8-1 through 8-4.

Table 8-1. The Customers Table

Field Name Data Type
Name Text
Company Text
Address Text
City Text
State Text
Zip Text
Email Text
CardType Text
CardNumber Text
ExpDate Text
Title Text

Table 8-2. The Authors Table

Field Name Data Type
Au_ID Long
Author Text
Year Born Integer

Table 8-3. The Title Author Table

Field Name Data Type
ISBN Text
Au_ID Long

Table 8-4. The Titles Table

Field Name Data Type
Title Text
Year Published Integer
ISBN Text
PubID Long
Description Text
Notes Text
Subject Text
Comments Memo
Special Boolean
Price Currency

© 1996 by Scot Hillier. All rights reserved.