Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Suppose you are given the James River Jewelry database design as follows: CUSTOM

ID: 3868062 • Letter: S

Question

Suppose you are given the James River Jewelry database design as follows:

CUSTOMER ( CustomerID, LastName, FirstName, Phone, Email)

PURCHASE ( InvoiceNumber, Date, PreTaxAmount, CustomerID)

PURCHASE_ITEM ( InvoiceNumber , ItemNumber, RetailPrice)

ITEM ( ItemNumber, Description, Cost, ArtistName)

OWNER ( OwnerID, Name, Phone, Email, AmountOwed)

JEWELRY_ITEM ( I temNumber, DateReceived, DateSold, NegotiatedSalesPrice, ActualSalesPrice, CommissionPercentage, OwnerID)

where

CustomerID in PURCHASE must exist in CustomerID in CUSTOMER

InvoiceNumber in PURCHASE_ITEM must exist in InvoiceNumber in PURCHASE

ItemNumber in PURCHASE_ITEM must exist in ItemNumber in ITEM

OwnerID in JEWELRY_ITEM must exist in OwnerID in OWNER

ItemNumber in JEWELRY_ITEM must exist in ItemNumber in ITEM

The OWNER and JEWELRY_ITEM tables are used to record data and maintain owner data about jewelry accepted on consignment.  JEWELRY_ITEM (which is a subtype of ITEM-n ote the referential integrity constraint) is used to record the negotiated sales price, the commission percentage, and the actual sales price for each item of consigned jewelry.

Assume that office personnel at James River Jewelry use a database application to record consignment data.

When an item is received on consignment, owner data are stored in OWNER if the owner is new; otherwise existing owner data are used.   New ITEM and JEWELRY_ITEM rows are created.   In ITEM, ItemNumber and Description are recorded, Cost is set to $0.00, and if there is an artist associated with the piece, ArtistName is entered.   For JEWELRY_ITEM, data are stored for all columns except DateSold and ActualSalesPrice. James River Jewelry personnel refer to these actions as an Acceptance Transaction.  

Later, if the jewelry item does not sell, the NegotiatedSalesPrice and CommissionPercentage values may be reduced.   This is called a Price Adjustment Transaction.

Finally, when an item sells, the DateSold and ActualSalesPrice fields for the item are given values, and the AmountOwed value in OWNER is updated by increasing AmountOwed by the owner's percentage of the ActualSalesPrice value.   This third transaction is called a Sales Transaction

Suppose James River Jewelry identifies three groups of users: managers, administrative personnel, and system administrators. Suppose further that managers and administrative personnel can perform Acceptance Transactions and Sales Transactions, but only managers can perform Price Adjustment Transactions.

James River Jewelry has developed the following procedure for backup and recovery. The company backs up the database from the server to a second computer on its network each night. Once a month, it copies the database to a CD and stores it at a manager’s house. It keeps paper records of all services provided for an entire year. If it ever loses its database, it plans to restore it from a backup and reprocess all service requests.

A) Which of the three application transactions must be made atomic (e.g., specify transaction boundaries) to prevent possible lost update? Why and why not?

B) Describe processing rights that you think would be appropriate for the identified three groups of company users.

C) Comment on the company’s strategy on DB backup and recovery. Describe any changes you think the company should make to its current backup and recovery scheme.

Explanation / Answer

A) Atomicity say that a perticular transaction must be completed successfully. If its executed then it should be executed completely other wise it should be rollbacked. Partial transaction is not allowed according to atomicity. The three transaction that should be maintain atomic are:

1) Price adjustment transaction must be atomic.
2) Transaction in which AmountOwned value in owner is updated should be atomic.
3) Sales transaction must be atomic.

B) The processing rights should be given in following ways:
1) First group of people should have only data read access, that is, select query should be allowed only.
2) Second group of people should have read/write access, that is, this group can select and update data.
3) Third group have super access, that can do the changes at schema level. Can run DDL commands on database.

C) The suggested changes are given below:

1) As we all knew that "Recovery is as good as your backup is", so i think we should take backup atleast twice in a month. This can leads to less data loss in case of any database related issue.

2) Backup and be taken as full backup as well as incremental backup.

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote