Appendix E – Advanced SQL
The tables with all their columns and data were created in question 2. Here we will link
them using foreign keys: The TOOL_USE table will have 2 foreign keys, one to refer to
the tool being used and the other to refer to the employee using the tool. These foreign
keys are needed to maintain the integrity of the data in the TOOL_USE table. We will
accept the defaults of NO ACTION for ON DELETE and ON UPDATE of both foreign keys:
we do not want to delete tool usage information, and we will not be changing the values
of our surrogate keys. Once all the data have been entered in question 2, the SQL to
create the foreign keys is the same for all systems:
ALTER TABLE TOOL_USE
ANSWERS TO JAMES RIVER JEWELRY PROJECT QUESTIONS
[NOTE: The James River Jewelry Project Questions are available online in Appendix D,
which can be downloaded from the textbook’s Web site:
www.pearsonhighered.com/kroenke.. The solutions for these questions will be included
in the Instructor’s Manual for each chapter and appendix.]
Note: Online Appendix E covers SQL Views and other advanced SQL topics, and
logically that material should be studied in conjunction with Chapter 3 on SQL.
Therefore, the James River Jewelry Project Questions for Appendix E are
presented in this location in this appendix.
For the database solutions for the Project Questions about James River Jewelry, see the
IRC files supplied and use:
• Microsoft Access:
• DBC–e08-JRJ.accdb