Before launching any of the following clean up actions, it is better if all the BW users accounts that have not been used for a long time (<6 months) be deleted from the system. This is because in some cases, data cannot be deleted if the user still exists.
| Main Parameter | Value |
|---|---|
| Last Use Date | current date - 365 |
1 - Go to transaction Se38
2 - Run program RSRD_ADMIN_BOOKMARKS_3X (For old 3.x version bookmarks)

3 - Select All users. For Created Before/Last Access, put Current Date - 365
4 - Select All bookmarks and delete
You need to repeat the select all + delete several times if necessary as the initial screen only shows a few bookmarks |
RSRD_ADMIN_BOOKMARKS_3X can only delete 3.x version bookmarks. Program RSWR_BOOKMARK_REORG can be used to delete 7.x bookmarks but the problem is that you cannot know if it's still in use - So it's not included in this process. |
1 - Go to transaction SE38
2 - Run program RSRD_BOOKMARK_REORGANISATION
3 - Input "365" in Older Than Days
4 - Uncheck "Test Call (No Delete)" - Otherwise no real deletion will be done

| Main parameter | Value |
|---|---|
Temporary Bookmark ID Older than (In days) | 365 |
Bookmark IDs Old than (In days) | 365 |
| Test Call (No delete) | Uncheck |
1 - Go to transaction SE38
2 - Run program RSWB_ROLES_REORG
3 - Choose "Only Examine BW Roles"

This report has several sections :
| Section | Explanation | Action |
|---|---|---|
| Incorrect References from Workbooks in Roles | References from workbooks in roles that do not exist in workbook storage | Delete all |
| Workbooks without Query Assignment | References to workbooks in roles that do not have a query assignment | DO NOT DELETE |
| Incorrect References from Workbooks in Favorites | References from workbooks in favorites that do not exist in workbook storage | Delete all |
| References from workbooks in favorites that do not exist in workbook storage | References to workbooks in favorites that do not have a query assignment | DO NOT DELETE |
| Unused Workbooks | Workbooks in workbook storage that are not referenced in roles or favorites | Delete all |
| Main tables cleaned |
|---|
| RSRWBSTORE AGR_HIER AGR_HIERT RSRWORKBOOK SMEN_BUFFC RSRWBINDEX RSRWBINDEXT |
This operation should only be done if temporary tables are taking a lot of space. Check in DB02 all tables starting with "/BI0/0" |
1 - Go transaction Se38
2 - Run program SAP_DROP_TMPTABLES

| Main tables cleaned |
|---|
| /BI0/0* |
The DTP error log can be analysed via program RSB_ANALYZE_ERRORLOG.
To delete the DTP error log :
1 - Go to transaction SE38
2 - Run program RSBM_ERRORLOG_DELETE
3 - Input "30 days" in the "but always older than ... days" parameter
4 - Check "Delete log"
5 - Run - If large, run in Background
| Main parameter | Value |
|---|---|
but always older than ... days | 30 |
| delete log | Checked |
| Main tables cleaned |
|---|
| RSBERRORLOG (+ indexes) |
1 - Go to transaction SE38
2 - Run program RSDDSTAT_DATA_DELETE
3 - Select all checkboxes for data to be deleted
4 - Free Date selection : Current Date - 365
5 - In the Date up until which data is to be deleted, select "Date Selection" and then enter Current date - 365 in the "Up to Day (Incl.)" field.
| Main parameter | Value |
|---|---|
Up to day (Inc) | Current Date - 365 |
| Main tables cleaned |
|---|
All RSDDSTAT* : RSDDSTATLOGGING (+Indexes) |
1 - Go to transaction SE38
2 - Run program RSTT_TRACE_DELETE

| Main parameter | Value |
|---|---|
Ignore Number of Last Days | 100 |
| Application Area | BW_BEX |
| Main tables cleaned |
|---|
RSTT_CALLSTACK |
1 - Go to transaction SE38
2 - Run program RSDQ_DYNP_GP_CLEANUP
3 - Check the PDOIT
4 - Execute the program
| Main tables cleaned |
|---|
DYNPSOURCE + corresponding LOB segments |
1 - Go to transaction SE38
2 - Run program RSSODFRE
3 - Select Minimum Age (Days) = 60
4 - Check the 2 delete boxes
5 - Uncheck Test Mode
6 - Execute the program
| Main parameter | Value |
|---|---|
Minimum Age (Days) | 30 |
| Test Mode | Unchecked |
| Delete documents linked | Checked |
| Delete unsent documents | Checked |
| Main tables cleaned |
|---|
SOFFCONT1 BCST_CAM BCST_RE BCST_SR SOC3 SOCS SOES SOFM SOOD SOOS SOST |
1 - Go to transaction Se38
2 - Run program : RSSO_DELETE_PRIVATE
3 - Select all types of messages (Inbox to Private Trash)
4 - For Inbox, check “All” instead of “Viewed”
5 - Uncheck Test Mode
6 - Run the program
| Main parameter | Value |
|---|---|
Minimum Age (Days) | 60 |
| Inbox | All |
| Test Mode | Unchecked |
| Delete unsent documents | Checked |
1 - Go to SE38
2 - Run program RSBCS_REORG
3 - Select "Specify Age (in Days)" and select from 60 to 9999.
4 - Uncheck the "Test Mode"

| Main parameter | Value |
|---|---|
Age in days | 60 to 9999 |
| Test Mode | Unchecked |
1 - Go to SE38
2 - Run program RSPC_INSTANCE_CLEANUP
3 - In Older than : current date - 365

| Main parameter | Value |
|---|---|
Older Than | Current Date - 365 |
| Delete Logs | Checked |
| Main tables cleaned |
|---|
RSPCINSTANCE RSPCINSTANCET |
1 - Go to SE38
2 - Run program RSPC_LOG_DELETE
3 - In the "Up to and including date" enter current date - 365

| Main parameter | Value |
|---|---|
Up to and including date | Current Date - 365 |
| Main tables cleaned |
|---|
RSPCLOGCHAIN RSPCPROCESSLOG |
This is already scheduled automatically (at least on WBP) |
1 - Go to SE38
2 - Run program RSBTCDEL2
3 - Run with default values and "Test Run" unchecked

| Main tables cleaned |
|---|
TBTCO |
1 - Go to transaction SE38
2 - Run program SBAL_DELETE
3 - Make sure the "Only logs which have reached their expiry date" is checked.
4 -
