NumberOfProducts
1 12
Question 9:
Picture 8.1
[0.5 mark]Create a trigger named tr_insert_Product_Subcategory for the insert statement on table Product so that when we insert one or more rows into the table Product, the system will
9 of 9
Paper No: 1
display the ProductID, ProductName, SubcategoryID, SubcategoryName, Category corresponding to the rows that have been inserted.
for example, when we execute the following statement, the results should be as in the following figure:
insert into Product (ProductID, Name, Cost, Price, SubcategoryID, SellStartDate)
values (1005, 'Product Test', 12, 15, 1, '2021-10-25')
ProductID ProductName Product Test
1005
SubcategoryID 1
SubcategoryName Mountain Bikes
Category Bikes
1
Zoom
Close
+ 100%