Enhancements
History of Enhancement -
Initiallly User-Exits were used as mode of enhancement. These use function modules as a source for user code. SAP provided hooks were a function module is called. This function module has a defined interface and has an include program. The user would add his code in this include program and activate it. Now when the standard transaction will be called so will the code added by the user at that specific point.
The main problem with user exits was that only a single implementation was possible. That means if an enhancement is included in a project that can not be reused as long as the project is active.
To over come this issue SAP came up with Badi's which supported multiple implementations. Now several users could create instances of the same object as it followed the OOPS concept. These enhancements were good with transactions but if an enhancement was required on a standard report than SAP gave what are known as Enhancement Spots. These were made available in version ECC 6.0 on.
To over come this issue SAP came up with Badi's which supported multiple implementations. Now several users could create instances of the same object as it followed the OOPS concept. These enhancements were good with transactions but if an enhancement was required on a standard report than SAP gave what are known as Enhancement Spots. These were made available in version ECC 6.0 on.
These spots would be implicit or explict.
In implicit they are available at the beginning of subroutines defined in the standard reports.Edit-> Enhancement operations->show implicit enhancement options. This will highlight all the implicit enhancements in the report.
In Explicit enhancement we have two different types of enhancements - Enhancement point and Enhancement section.
Enhancement point - SAP has some standard functionality defined for a report , but it may be required that you'll need to add your own code. In this case the code that you'll add will be executed along with the standard code.
Enhancement section - SAP has its standard functionality defines but it may not suit your requirement, in that case you may need to add your code and you'll need that code to be executed only. By this method the existing code is automatically commented and a copy of the same code is available to edit.
After executing the report only your code will be executed and the standard code will be bypassed.
To identify an enhancement spot (more specifically and enhancement point/section) that will be mentioned on code as shown below
On the application toolbar there will be a button for enhance (Shift+F4). Place your cursor on the name of the enhancement (name just after the enhancement point keyword). This will cause the screen to white with grey text.Right click on the name and select enhancement implementation->create.
This will allow you to add your code in case of enhancement point and will create a copy of the existing code in editable mode and comment the existing code in case of enhancement section.