enter your entire script below. do not include statements to drop objects as your script will be executed against a clean schema. you may include select statements in sub queries in your insert statements, but do not include select queries that return records for display. continue to use the purchase 61 and purchase item 61 tables that you created and modified in the previous problems. increase the shippping cost of every purchase from manufacturers in massachusetts ('ma') by 10%. round your calculations to two decimal points. hint: use the in clause. do not use a join

Respuesta :

UPDATE purchase61

SET shipping_cost = ROUND(shipping_cost * 1.10, 2)

WHERE manufacturer IN (SELECT manufacturer FROM purchaseitem61 WHERE state = 'MA')

How to update the column?

This statement will update the shipping_cost column in the purchase61 table for every purchase where the manufacturer is in the list of manufacturers in Massachusetts, as determined by the subquery. The shipping cost will be increased by 10% by multiplying it by 1.10, and then rounded to two decimal points using the ROUND function.

Note that you should not use a join in this statement, as the IN clause allows you to compare values in the manufacturer column with the results of the subquery without using a join. This can make the statement more efficient and easier to read.

To Know More About SQL, Check Out

https://brainly.com/question/13068613

#SPJ1

Otras preguntas