Changes between Version 2 and Version 3 of DML final
- Timestamp:
- 09/29/25 20:56:42 (3 weeks ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
DML final
v2 v3 116 116 FeedbackID integer PRIMARY KEY, 117 117 CustomerID integer, 118 ProductID integer,119 118 Rating integer CHECK (Rating BETWEEN 1 AND 5), 120 119 Comment text, … … 122 121 TransactionID integer, 123 122 CONSTRAINT feedback_customer_fk FOREIGN KEY (CustomerID) REFERENCES customer(CustomerID), 124 CONSTRAINT feedback_product_fk FOREIGN KEY (ProductID) REFERENCES product(ProductID),125 123 CONSTRAINT feedback_transaction_fk FOREIGN KEY (TransactionID) REFERENCES procurement(TransactionID) 126 124 ); … … 136 134 ); 137 135 138 CREATE TABLE customer_product (139 CustomerID integer NOT NULL,140 ProductID integer NOT NULL,141 CONSTRAINT customer_product_id PRIMARY KEY (CustomerID, ProductID),142 CONSTRAINT customer_product_customer_fk FOREIGN KEY (CustomerID) REFERENCES customer(CustomerID),143 CONSTRAINT customer_product_product_fk FOREIGN KEY (ProductID) REFERENCES product(ProductID)144 );145 136 146 137 CREATE TABLE product_maintenance ( … … 159 150 CONSTRAINT employee_maintenance_maintenance_fk FOREIGN KEY (MaintenanceID) REFERENCES maintenance(MainID) 160 151 ); 161 162 152 }}}