I have an entity Order
.
The order has information on date, client, associate who handled order etc.
Now the order also needs to store a state i.e. differentiate between won orders and lost orders.
The idea is that a customer may submit an order to the company, but could eventually back out.
(As domain info, the order is not of items. It is a services company that tries to handle clients and makes offers on when they can deliver an order and at what price etc. So the customer may find a better burgain and back up and stop the ordering process from the company).
The company wants data on both won orders and lost orders and the difference between a won order and a lost order is just a couple of more attributes e.g. ReasonLost
which could be Price
or Time
.
My question is, what would be the best representation of the Order
?
I was thinking of using a single table and just have for the orders won, the ReasonLost
as null.
Does it make sense to create separate tables for WonOrder
and LostOrder
if the difference of these new entities is not significant?
What would be the best model for this case?