Order Partial Closing

 

Hi friends,

I coded to close my order partially - for example close only 2 lots of a 10 lots order- and then I found out that after the partial closing (closing some of the order lots) the order number has been changed into a new number. I also tested it manually in other brokers and there was the same result that after partial closing the order number changed to a new number. I want to ask you guys is the order number change to a new number after partial closing?

thanking in advance for your kind guidnace

 
parham.trader:

I want to ask you guys is the order number change to a new number after partial closing?

Short answer: yes, a partial close creates a new ticket for the remaining volume.

Longer answer: yes, but note that the open time of the new ticket is the original open time of the trade, not the time of the partial close which creates the new ticket.

Even longer answer, for reference: things such as MAM systems usually do their own, completely different handling of partial closes. If you have external trades being placed onto an account, any partial closes may be recorded in a different way to what you expect from your own partial closes. In addition, a few brokers also used to have bespoke and unusual handling of manual partial closes by traders, but I haven't seen such a thing for a long time.

 
JC:

Short answer: yes, a partial close creates a new ticket for the remaining volume.

Longer answer: yes, but note that the open time of the new ticket is the original open time of the trade, not the time of the partial close which creates the new ticket.

Even longer answer, for reference: things such as MAM systems usually do their own, completely different handling of partial closes. If you have external trades being placed onto an account, any partial closes may be recorded in a different way to what you expect from your own partial closes. In addition, a few brokers also used to have bespoke and unusual handling of manual partial closes by traders, but I haven't seen such a thing for a long time.


Your complete response is highly appreciated,

So for simplifying the coding process, I assume it for always that after partial closing I will get a new ticket number for the remaining volume.

again thank you for the time you dedicated.