Adjusting Programs

Whenever you alter a program using the Modification Assistant, most changes can be adopted automatically because source comparison now takes place at the modularization unit level (that is routine, module, or event level) and not at the transport object level.

Modifications to modularization units are automatically adopted at release upgrade if:

  • They have only been changed by the customer, but not in the original version
  • They have been newly created by the customer

Automatic adoption of modifications at release upgrade is not possible if both the original version of the modularization unit and the customer version have been changed (for example, if interface changes have been made that affect either function modules or subroutines, or if the source code has been altered). For these kinds of adjustments the Modification Assistant does, however, offer support in the form of the splitscreen editor.

You must edit these programs manually using the editor whenever the part of program changed by the customer no longer exists. They can be found in the adjustment log marked as unresolved problems. In transaction SPAU, a stop sign icon denotes these problems. Click on the icon to display the log file.

Example:

A customer has changed the name of a subroutine. This subroutine is meant to perform authorization checks in a manner that differs from the standard. The modifications to the subroutine can be adopted automatically, if SAP has not changed the subroutine in its new release. However, since the modularization unit in the new original differs from the one in the old original, automatic adjustment is not possible in this case and the splitscreen editor is called. The system accepts all modifications to the SAP original that can be adopted automatically before it calls the editor.

The window on the left displays the new SAP original, while the window on the right displays the source code modified by the customer.

The splitscreen editor is called in comparison mode. The positioning pushbutton Next difference allows you to scroll to the next source code difference between the two programs. At this point, you must decide whether you want to transfer your modifications the new original or if the original should remain unchanged. To make changes to the original, proceed as follows:

  • Place your cursor on the appropriate passage in the modified source (right side) or select a portion of the source code and then choose Copy.
  • Place your cursor on the corresponding passage in the original (left side) or select the block of code you want to replace and choose either Insert or Replace. This inserts the code you copied to the buffer into the original.

If further differences occur, choose Next difference to scroll to the next modification that was not automatically adopted by the system.

You may also use the combination Next similarity and Next difference to navigate forward.

After having made all necessary modifications, save your changes. A dialog box appears, asking you to confirm that you have adjusted all modifications. The following statistics are also displayed:

  • Units to be modified
  • Units automatically adjusted
  • Units manually adjusted

If you answer ‘yes’, all modifications not yet adopted are lost. These are lost forever as soon as you leave the splitscreen editor.

If your new original version contains code that you would like to replace with unmodified code from the previous version, use Block/buffer menu to copy it to the buffer and Insert/Replace to insert it into the original.

Further information about how to use the editor can be found in the section on The Splitscreen Editor.