Imported from previous forum
The 4.2 state change matrix D6 shows an order that has been replaced via cancel/replace,and it seems to show the new (replacement) order having a status of ‘replaced’ at one point, stating that “‘replaced’ has a higher priority than ‘new’”. I had always thought that order status ‘replaced’ meant that the order had been superceded by another; the new, active order should not be marked ‘replaced’.
In volume 4 of the fix 4.3 spec, that idea seems to be supported. Reference 8 of the order state change matrices is the identical case to 4.2 D6 (Zero-filled order, cancel/replace request issued to increase order qty), but the 4.3 spec shows the order status of the new order going to ‘new’, not to ‘replaced’, at time 5. Is it safe to assume that the 4.2 D6 state change case is erroneous, or is there a 4.2 vs 4.3 spec change that accounts for the difference?
[ original email was from Ryan Pierce - rpierce@taltrade.com ]
That’s a really interesting question. This indicates a significant change between 4.1/4.2 order processing and 4.3 order processing.
FIX 4.1 and 4.2 had a state of Replaced which sits between New and Partially Filled in precedence. It is a state for an order that has been replaced at least once but has never been filled, and doesn’t have any cancels or cancel/replaces pending.
This has two main problems.
#1. The state makes no business sense. An order that has been changed that has partial fills is still OrdStatus=Partially Filled, yet an order that has been changed but has not had any partial fills is OrdStatus=Replaced. Why should we distinguish between whether a cancel/replace has occurred if the order has no partial fills, but not do so if it has partial fills?
#2. It limits state transitions. The protocol works for orders that transition to New and then get replaced, but what happens if an order is Pending New and gets cancel/replaced before it can go live?
Conceptually, Replaced is not a state, like New or Partially Filled. It is an action, hence an ExecType. So one could say ExecType=Replaced OrdStatus=New, ExecType=Replaced OrdStatus=Partially Filled, or ExecType=Replaced OrdStatus=Pending New to accept a change, depending on the state of the order at the time the cancel/replace takes effect.