Hello Pooja.
A dynamic update would mean "for each order created, update my table".
The normal way is, call an action to update, based on how much you placed on the order.
-You have product id and quantity.
-You search inventory by productid, edit that record to minus quantity, and do an update.
I made this example where you update stock. If the number is positive, you add stock. If negative, you remove stock.