Database Reference
In-Depth Information
F IGURE 9.4
The beginning of the physical model for Mountain View Music's
products
Notice that we have named the tables using the guideline we discussed
earlier. In addition, you can see the implementation of our surrogate
primary key, a column named objid in all tables. Tables such as tbl_
product_instance have a composite primary key that is made up of the pri-
mary keys from the two joined tables. As it happens, this is also how we
name the foreign key columns—the shortened table name (no “tbl_” pre-
fix) followed by “_objid.” We look at foreign keys in the next section.
Inventory Submodel
Next, we look at the entities in the Inventory submodel. This model is sim-
ilar to the Products submodel in that we don't have a lot of work to do. The
entities we will work with are listed here and shown in Figure 9.5.
Products
Product Instance
 
Search WWH ::




Custom Search