WilliamSelvage
6 years agoQrew Trainee
Change Orders
Hypothetical situation: There are three tables; Parts, Orders, and Line Items. Parts and Orders have many Line Items.
One part has become obsolete and is no longer able. There is however a direct replacement for this part.
Typically, we would need to open each Line Item and individually change the related part one-by-one.
We would like to create a new table called Change Orders which would track these types of changes. This would store the old related part, and the new related part.
Once a CO is approved, a function is run and the Change Order would swap all the related parts in Line Items, as long as the order has not been shipped.
An added bonus if we can calculate the financial gains/losses from a given CO prior to implementing.
Where would I begin?
Thank you in advance,
One part has become obsolete and is no longer able. There is however a direct replacement for this part.
Typically, we would need to open each Line Item and individually change the related part one-by-one.
We would like to create a new table called Change Orders which would track these types of changes. This would store the old related part, and the new related part.
Once a CO is approved, a function is run and the Change Order would swap all the related parts in Line Items, as long as the order has not been shipped.
An added bonus if we can calculate the financial gains/losses from a given CO prior to implementing.
Where would I begin?
Thank you in advance,