Introduction
To restrict or unrestrict IDoc statuses, you can use transaction code WE47 to modify the status settings. This allows you to define which IDoc statuses are considered valid for different actions like deletion or archiving. You can also use transaction BD87 to reprocess or delete IDocs that have specific statuses, according to SAP Help Portal.
Check out my post for a detailed explanation of Archiving IDocs in SAP (Write & Delete): A Step-by-Step Guide for First-Time Implementation
Why WE47 Matters in IDoc Archiving
The transaction WE47 (Status Management) defines which IDoc statuses are deletable during the Delete phase of archiving.
IDocs with a status code that is marked as “not deletable” in WE47 will remain in the system even after a successful archiving write and delete run.
Example: Status 64 (IDoc ready for processing) is not deletable by default. If such IDocs are selected during archiving, they will be archived but not deleted.
Key Notes Before Starting
Always coordinate status changes with BASIS + Functional teams.
Document all changes to WE47.
Maintain a separate list of “critical statuses” to avoid deletion risks.
How to Identify Which Statuses Block Deletion
Step-by-Step
Use transaction code WE47 to access the IDoc status maintenance screen.
Navigate to the relevant section within WE47 to define which IDoc statuses are allowed for certain actions.
You’ll now see whether the “Deletion” flag is set to poss (possible for deletion) or excluded (from deletion).
Unrestricting IDoc Status (Allow Deletion)
To allow deletion of an IDoc in a specific status:
Detailed Steps:
Use transaction code WE47 to access the IDoc status maintenance screen. .
In the list, search for the status code (e.g., 64, 51).
Select the entry and double-click to open it.
Check the “Poss” radiobutton.
Click Save.
Re-run the Write & Delete Program to ensure the deletion of idocs with above status
Check out my post for a detailed explanation of Archiving IDocs in SAP (Write & Delete): A Step-by-Step Guide for First-Time Implementation
Outcome : Now, the previously blocked IDocs will be successfully deleted.
Restricting IDoc Status (Prevent Deletion)
Sometimes you may want to protect certain IDoc statuses from being accidentally deleted—like those that haven’t been processed yet or are under investigation.
Steps to Add Restriction:
Go to WE47.
Click New Entries or select an existing status.
For the given status code, mark the radio button “ Excluded ”.
Save your entry .
Check out my post for a detailed explanation of Archiving IDocs in SAP (Write & Delete): A Step-by-Step Guide for First-Time Implementation
Outcome : Now any IDoc in this status will be excluded during deletion runs.
Reprocess or Delete IDocs (if needed):
Changing an Existing Status Entry
You can switch a status between restrict/unrestrict anytime, but use caution in production systems.
Best Practice: Only unrestrict after verifying business approvals. Unarchived error IDocs might contain pending or critical info.
ActionToolResultCheck which IDocs weren’t deletedSE16N → EDIDCIdentify blocked statusesView/Change status restrictionWE47Check ” Poss “Protect sensitive statusesWE47Check ” Excluded “Re-archive undeleted IDocsSARA → Write + DeleteComplete removal
Conclusion
Using WE47 wisely helps you take full control over IDoc lifecycle management. Whether you want to retain unprocessed IDocs or clean up your system, this tool plays a critical role in SAP data governance.
If you’re performing IDoc archiving for the first time or troubleshooting undeleted records, make WE47 your go-to transaction!
IntroductionTo restrict or unrestrict IDoc statuses, you can use transaction code WE47 to modify the status settings. This allows you to define which IDoc statuses are considered valid for different actions like deletion or archiving. You can also use transaction BD87 to reprocess or delete IDocs that have specific statuses, according to SAP Help Portal. Check out my post for a detailed explanation of Archiving IDocs in SAP (Write & Delete): A Step-by-Step Guide for First-Time Implementation Why WE47 Matters in IDoc ArchivingThe transaction WE47 (Status Management) defines which IDoc statuses are deletable during the Delete phase of archiving.IDocs with a status code that is marked as “not deletable” in WE47 will remain in the system even after a successful archiving write and delete run.Example: Status 64 (IDoc ready for processing) is not deletable by default. If such IDocs are selected during archiving, they will be archived but not deleted. Key Notes Before StartingAlways coordinate status changes with BASIS + Functional teams.Document all changes to WE47.Maintain a separate list of “critical statuses” to avoid deletion risks. How to Identify Which Statuses Block DeletionStep-by-StepUse transaction code WE47 to access the IDoc status maintenance screen.Navigate to the relevant section within WE47 to define which IDoc statuses are allowed for certain actions.You’ll now see whether the “Deletion” flag is set to poss (possible for deletion) or excluded (from deletion). Unrestricting IDoc Status (Allow Deletion)To allow deletion of an IDoc in a specific status:Detailed Steps:Use transaction code WE47 to access the IDoc status maintenance screen. .In the list, search for the status code (e.g., 64, 51).Select the entry and double-click to open it.Check the “Poss” radiobutton.Click Save.Re-run the Write & Delete Program to ensure the deletion of idocs with above statusCheck out my post for a detailed explanation of Archiving IDocs in SAP (Write & Delete): A Step-by-Step Guide for First-Time Implementation Outcome : Now, the previously blocked IDocs will be successfully deleted. Restricting IDoc Status (Prevent Deletion)Sometimes you may want to protect certain IDoc statuses from being accidentally deleted—like those that haven’t been processed yet or are under investigation.Steps to Add Restriction:Go to WE47.Click New Entries or select an existing status.For the given status code, mark the radio button “ Excluded ”.Save your entry .Check out my post for a detailed explanation of Archiving IDocs in SAP (Write & Delete): A Step-by-Step Guide for First-Time Implementation Outcome : Now any IDoc in this status will be excluded during deletion runs. Reprocess or Delete IDocs (if needed):If you need to reprocess or delete IDocs with specific statuses, use transaction code BD87.Changing an Existing Status EntryYou can switch a status between restrict/unrestrict anytime, but use caution in production systems.Best Practice: Only unrestrict after verifying business approvals. Unarchived error IDocs might contain pending or critical info.ActionToolResultCheck which IDocs weren’t deletedSE16N → EDIDCIdentify blocked statusesView/Change status restrictionWE47Check ” Poss “Protect sensitive statusesWE47Check ” Excluded “Re-archive undeleted IDocsSARA → Write + DeleteComplete removal ConclusionUsing WE47 wisely helps you take full control over IDoc lifecycle management. Whether you want to retain unprocessed IDocs or clean up your system, this tool plays a critical role in SAP data governance.If you’re performing IDoc archiving for the first time or troubleshooting undeleted records, make WE47 your go-to transaction! Read More Technology Blog Posts by Members articles
#SAP
#SAPTechnologyblog