SAP Learning Blog Posts
Get updates on SAP learning journeys and share your own experiences by contributing a blog post to the SAP Learning group.
cancel
Showing results for 
Search instead for 
Did you mean: 
Former Member
28,123


How to delete old batch sessions from SM35?  As the no of session are very huge, SM35 cannot be accessed.


Department users have created tons of batch input sessions and processed them with SM35. The users did not care about deleting unwanted sessions and there are a lot of old sessions, with almost any status (in processing/in background/processed/errors). All of them are junk (in your terms), and have to be removed from the system.

You can delete unwanted sessions with abap program RSBDCTL6 at once and then setup a background job that deletes the sessions for a specific session, user who created the session, date range, older than x days etc. that runs on a regular basis.

Alternatively, you can run program RSBDC_REORG.  However, tests showed that this program may not be suitable for sessions that have a status other than processed.

For those sessions which have status OTHER than "processed" you will have to delete manually.

The batch-input sessions are located in the tables APQI and APQD.

If that is so, please delete the corresponding entry from table APQL and after that you will be able to delete the "In Process" sessions from SM35 Tcode.

Please use the session name to search the entry in table APQL.

I have faced the same problem and I was able to resolved using this way.

Also, review the following SAP Notes:

16083 - Standard jobs, reorganization jobs

18307 - Batch input logs and reorganization

147354 - Batch input: Reorg. and delete sessions and logs

RSBDCREO *only* deletes sessions which are in status "processed". The reason for this is that this report is written for an automatic cleanup and therefore should never remove sessions that are not completely processed. The report also only deletes the logs for sessions which are already deleted (or scheduled for deletion in the same run).

This means that when you check both options on the initial screen of RSBDCREO, the following sessions and logs will be deleted:

  1. 1. Processed sessions and their logs
  2. 2. Logs for which no sessions exist anymore

Read also
Scheduling a New Job in SAP