Purchase Solution

Create Table Statement

Not what you're looking for?

Ask Custom Question

NOTE: You do NOT need to run/execute the script.

Create a new table to be housed in the USERS01 tablespace. The table name will be PRECIOUS_METAL_PRICE and it will be used to store a history of the price of various precious metals. New rows are added to the table on a one-every-two-hours ratio. The table needs to have a relationship back to a parent table named METALS, which lists various precious metals like Gold, Silver, Zinc, etc. The table has a four-byte primary key ID number (METAL_ID) and a description of the metal. As you write the CREATE TABLE statement for this new table, you need to address the following points: The columns are named PRICE, PRICE_DATETIME, and TIME_BETWEEN. The following offers some additional direction on how the table should be created.
• The PRICE can contain fractions of a penny down to thousandths of a penny, but the whole price will always be under 1000 dollars. A column named TIME_BETWEEN will store the number of days (up to 99 days), hours, minutes, and seconds (to the hundredth of a second) between the current record and the previous record. The table is never updated; only new data is inserted. Therefore, you want to minimize the storage space saved for updates.

• Taking an average row length as 24 bytes, and an average of 12 inserted records per day, you want the table to be created with enough storage space for approximately 6 months; but at the same time, you do not want to waste unused space (try to be as exact as you can).

Purchase this Solution

Solution Summary

The expert creates table statements.

Solution Preview

NOTE: You do NOT need to run/execute the script.

Create a new table to be housed in the USERS01 tablespace. The table name will be PRECIOUS_METAL_PRICE and it will be used to store a history of the price of various precious metals. New rows are added to the table on a one-every-two-hours ratio. The table needs to have a relationship back to a parent table named METALS, which lists various precious metals like Gold, Silver, Zinc, ...

Purchase this Solution


Free BrainMass Quizzes
Basic Computer Terms

We use many basic terms like bit, pixel in our usual conversations about computers. Are we aware of what these mean? This little quiz is an attempt towards discovering that.

Basic UNIX commands

Use this quiz to check your knowledge of a few common UNIX commands. The quiz covers some of the most essential UNIX commands and their basic usage. If you can pass this quiz then you are clearly on your way to becoming an effective UNIX command line user.

Word 2010: Tables

Have you never worked with Tables in Word 2010? Maybe it has been a while since you have used a Table in Word and you need to brush up on your skills. Several keywords and popular options are discussed as you go through this quiz.

Word 2010: Table of Contents

Ever wondered where a Table of Contents in a Word document comes from? Maybe you need a refresher on the topic? This quiz will remind you of the keywords and options used when working with a T.O.C. in Word 2010.

C++ Operators

This quiz tests a student's knowledge about C++ operators.