Question: Write the following assertions. The database schema is from the PC example: Product(maker, model, type) PC(model, speed, ram, hd, price) Laptop(model, speed, ram, hd, screen,
Write the following assertions. The database schema is from the "PC" example:
Product(maker, model, type)
PC(model, speed, ram, hd, price)
Laptop(model, speed, ram, hd, screen, price)
Printer(model, color, type, price 
b) A manufacturer of a PC must also make a laptop with at least as great a processor speed.
c) If a laptop has a larger main memory than a PC, then the laptop must also have a higher price than the PC.
d) If the relation Product mentions a model and its type, then this model must appear in the relation appropriate to that type.
ASSERTIONS Comparison of Constraints The following table lists the principal differences among attribute-based checks, tuple-based checks, and assertions. Type of Constraint Attribute- based CHECK Tuple- based CHECK Assertion Where Declared With attribute Element of relation schema Element of database schema When Activated On insertion to relation or attribute update On insertion to relation or Guaranteed to Hold? Not if subqueries Not if subqueries tuple update On any change to Yes any mentioned relation
Step by Step Solution
3.38 Rating (164 Votes )
There are 3 Steps involved in it
To write assertions for the given database schema we need to express each conditi... View full answer
Get step-by-step solutions from verified subject matter experts
