Skip to Content
Author's profile photo Ita Curran

How to archive and delete products in a CRM Production System

In SAP CRM a report is available to delete products from the system called COM_PRODUCT_DELETE_SINGLE (also COM_PRODUCT_DELETE_ALL).

This report however cannot be run on a production system and it contains code to check and prohibit this. The reason for this is because SAP do not recommend deleting master data from a production system.

However it can happen that for whatever reason, it is necessary to remove a product or products from a production system. The best and recommended
way to do this is to archive the product in question.

This document provides a detailed step by step description of the steps required in order to achieve this. It is something I have been asked to provide in the past and thought it was a good idea to share in general.

The following are the steps required

1. Mark the product you wish to archive. The easiest way to do this is to use transaction COMMPR01.

Capture.PNG

If you wish to mark more than one product as ‘to be archived’ then create the report ZCHANGE_PRODUCT_STAT.

Please see SAP note 768918 for more information on this. Once created, run the report in your system by providing the desired product ID’s.

You can also do so in the WebUI as follows:

Capture.PNG

In New Status dropdown, choose ‘To archive’

2. Next run transaction SARA with Archiving object = PRODUCT_MD. Hit Enter and you will see the following steps:

/wp-content/uploads/2014/11/capture001_597316.png

3. Preproc -> Click on this button create your own variant and include the product ID(s) to be archived. Note that these product ids are the ones marked ‘to be archived’ as mentioned in step 1.

Capture002.PNG

Next click on the ‘Start date’ and select ‘Immediate’ and Save. Now click on ‘Spool Params’ and select an output device (this is something you must decide or your basis team can help. This parameter will output the archived product in a flat file)

After this hit the Execute button to execute the preproc step.

4. You will again be taken to the main SARA screen. Now click Write button. Maintain ‘Start Date’ and ‘Spool Params’ as above, then execute the Write step by hitting the Execute button again

5. Again in the main screen, click the ‘Delete’ button. In the archive selection button, a pop up will be thrown up. Select the recent file which has been created (it will be mostly with the current date). This file is the one which was created earlier.

/wp-content/uploads/2014/11/capture003_597321.png

6. From the main screen, Execute the ‘Delete’ step in the same way as described above using the Execute button.

7. Again in the main screen, click ‘PostProc’ button. Execute the ‘PostProc’ step by hitting the execute button. Once this step has completed, the product will be archived

At any time during the process, you can check what has happened at each step by clicking on the Job icon. Here you will see the details as follows:

Capture004.PNG

Please also refer to SAP Note 768918

Assigned Tags

      10 Comments
      You must be Logged on to comment or reply to a post.
      Author's profile photo Former Member
      Former Member

      Hi Ita, nice blog!

      Author's profile photo Peter Murphy
      Peter Murphy

      Excellent Blog Ita.

      Author's profile photo Bernadette Fredericks
      Bernadette Fredericks

      Thanks for the detailed blog Ita.  Very useful.

      Author's profile photo Dean Yan
      Dean Yan

      Hi Ita,  Thanks 🙂

      Usful blog !

      Author's profile photo Luís Pérez Grau
      Luís Pérez Grau

      Hi Ita,

      Why are you archiving using SAP GUI? is not possible to do it via WebUI?

      Cheers!

      Luis

      Author's profile photo Ita Curran
      Ita Curran
      Blog Post Author

      Hello Luis,

      Thank you for your feedback. You are correct that the WebUI can be used to set status 'To be Archived' and I have added a screenshot to show this.

      With regard to transaction SARA, it can only be run in SAP GUI.

      Thanks,

      Ita

      Author's profile photo Luís Pérez Grau
      Luís Pérez Grau

      Thanks for adding the WebUI screen 🙂 as SARA is something for admins/consultants make sense there's no WebUI support.

      Author's profile photo Former Member
      Former Member

      Very Good Blog works pretty well.

      Author's profile photo Julin Xin
      Julin Xin

      Useful blog!

      Thanks Ita.

      Author's profile photo Venkata Krishnachaitanya Sakamuri
      Venkata Krishnachaitanya Sakamuri

      Hi Ita,

       

      But these actions are not triggering appropriate IDOCs with correct status. Is it by design or need to do some configuration.