Sales are managed with two number sequences :
When you create a sale, it takes an incremental number (+1) from the last created sale on your account.
When you close a sale, it takes a new incremental number (+1) from the last closed sale on your store. This number sequence follows a single, continuous and chronological sequence for each point of sale of your account.
The number sequence of closed sale is different than the number sequence of created sales to keep a continuous recording of the sales :
The format of a close sale number is : YYYY-MM-SS-XXX
where YYYY-MM is the year and month when the sale is closed, SS is the store ID where the sale is done, and XXX the incremental number of the closed sale on the month.
Ex: sale number 2020-10-2-340 is the 340th closed sale on October 2020 performed on store ID 2.
Before closing a sale, only the created sale number is printed on proforma receipts.
After closing a sale, the closed sale number is printed on receipts and invoices.
Invoices and receipts are sharing the same continuous and chronological number sequence.