How to improve the performance of MB5B
General recommendations:
1. Request the users to be more selective in their search criteria. For transaction "MB5B", we recommend to use "material number", "plant" and to enter two defined "selection dates". If you (for example) leave the material number or the selection date 'blank', the report will of course take a long time and maybe produce a dump. However, this is no software error as there is alway a limit to the performance of selection reports.
2. Create a more suitable secondary index on the table MSEG to suit your selection preferences.
3. Consider Archiving some of the contents of the table which are no longer necessary. The relevant archiving objects are MM_MATBEL and MM_SPSTOCK and can be archived via txn SARA.
You might have lots of entries in tables MSEG and MKPF. Please try the transaction again with the material number specified in the selection and see if this makes a difference.
Note: MB5B was not designed to work as a mass data report, therefore Archiving of material documents (SARA -> Object MM_MATBEL) and decreasing the amount of the selected materials are the main recommendations.
A workaround which makes MB5B able to work for mass data business requirements can be found in the note 1005901, which includes a custom development design in order to make MB5B able to work with mass data. An experienced ABAP developer should be able to implement this functionality within 2-3 days with the help of the note 1005901.
DB specific:
- Implement the latest optimiser merge fix patch as per SAP Note 981875-
- Implement the above listed _fix_control parameters as per SAP Note 830576
176754 point 56.
Kindly also review the following attached notes:
1005901 MB5B: Performance problems
773673 MB5B: Accessibility conver
921165 MB5B: Improving the runtime using database hints