Back to the First Savepoint
MediumDescription
A sale is set up in one transaction:
- Toys (
category_id8): 10% off; then set a savepoint - Books (
category_id2): 20% off; then set another savepoint - Sports (
category_id5): 30% off
The manager cancels both the Books and the Sports discounts. With one rollback, go back to the point just after the Toys discount. Then:
- Books: 5% off instead
- commit
Show product_id, category_id and price of the products in categories 2, 5 and 8.
End your query with ORDER BY product_id.
Tables
| products |
|---|
| product_id (PK) |
| product_name |
| category_id (FK) |
| price |