Try our conversational search powered by Generative AI!

Support for selecting whether catalog import should skip price and inventory handling or not


If an imported catalog xml file does not contain prices, existing prices are removed. This is due to importer using an empty IPriceValue list and saving it using PriceService.SetCatalogEntryPrices(...). That service/method expects to have a complete set of prices, and that combined with an empty list leads to all prices being lost.

However, the same logic does not apply to inventories. Existing inventory rows are kept even if they are not added to the xml. Current implementation is contradictory and confusing. One "just has to know" how importer works with different kinds of data.

One suggestion for a better solution is to e.g. provide boolean flags in the public interface of importer (Mediachase.Commerce.Catalog.ImportExport.CatalogImportExport) for controlling if prices or inventory should be completely ignored by the importer.

Oct 02, 2017 8:17

Hi Tomi,

I agree that this is a valid case, we will look into it.

The current workaround is to have make your implementation of IPriceService do not delete prices if the price list is null. 

And inventories and prices, while have fairly similar characteristics, they are not the same, so there might be difference in the way they behave.

Oct 02, 2017 9:33

Hi Tomi,

I have started to investigate this issue and cannot reproduce on Commerce 11 (there is a check that prevents prices being saved if the list of prices is empty). Which version are you running on? 

Oct 04, 2017 14:09

Commerce version is

Oct 04, 2017 14:22

Can you provide me with a sample catalog.xml where you observe this behavior? I'm unable to reproduce the issue on Commerce 11.x

Send by email to magnus(dot)strale(at)episerver(dot)com


Oct 05, 2017 10:24
This thread is locked and should be used for reference only.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.