I have the occasional customer request to change style or size of the clothes they order from my shop.
When I export the orders into CSV to create a work list, the original items I've removed still show as being part of the order and there's no way of easily seeing which items were removed. Is there a way of removing the item or tagging it in some way, so that these products can be recognised?
It also becomes a nightmare when trying to work out how much has been sold of individual products, if these removed ones are still showing. Surely I'm doing something wrong and this isn't how it's been purposefully built?
You are right in that the original order line remains and actually shows quantity 1 where it should be 0. You could edit the quantity to a random value like 999 but if you have inventory controls on than that won't be best option.
We found this problem ourselves developing one of our order processing integrations. One of our processes actually edits the order and removes the original line and replace with new ones. If it is a big issue we could work out an automation to help you with this process. You may not even need the csv file.
I agree that it's confusing and troublesome that orders exported to CSV include removed items. I guess it wasn't purposefully built this way but it was an oversight from Shopify. When they added the ability to edit orders they didn't update the export feature.
Internally, in the Shopify API, order line items have 2 fields denoting quantity. There is quantity and fulfillable_quantity. Removed items have fulfillable_quantity set to 0, while the quantity field keeps the original quantity. Unfortunately, the built-in CSV export doesn't include the fulfillable_quantity field.
If you are open to solving this problem with an app, then you could use Exporteo. It's the app I developed to export orders in a customizable format, including fields not available in the build-in CSV export. I'm happy to help you with setting it up.
Hope this helps,