Login Page - Create Account

Support Board


Date/Time: Tue, 21 May 2024 05:37:53 +0000



Post From: How to detect

[2020-07-16 16:19:41]
j4ytr4der_ - Posts: 918
I'm working on a spreadsheet formula that would be able to detect orphaned orders, where there was an entry order but for whatever reason it's gone now and its OCO bracket (for example) might still exist. This is a situation that shouldn't happen, but occasionally has so I want an alert any time it could happen.

The easiest way to see this IMO is to create a simple bracket OCO with say a 20-tick offset, then place a long position followed by a short position. The two positions will cancel out, leaving only the brackets behind, for both orders.

Detecting the presence of working orders without a position is easy, but unfortunately that will also be true any time there is a legitimate limit order anywhere. And I can't figure out a way to detect only "child" orders vs. "parent" orders.

Is there any way to accomplish what I was looking to do, in detecting these "orphaned child orders"?