The Enhancement and Switch Framework, along with exits and routines, are used to enhance SAP Sales and Distribution systems. In this chapter, you’ll learn the differences between each of the enhancement techniques and where to find them.
Before introducing the different ways you can enhance the existing Sales and Distribution (SD) functionality with ABAP code, you need to understand that any customization applied to the SAP standard code should always be the last resort and the end result of vigorous contemplation. Why?
In other words, by creating custom code enhancements to your SD component, you are introducing new software objects that might have a detrimental effect on some or all of the benefits just listed. Therefore, it’s important to analyze, understand, and communicate the potential impact of any code customization.
Before undertaking any custom enhancements using ABAP code, developers need to consider the following five important questions:
Routines, user exits, and customer exits (in some parts) leave a fair amount of responsibility with the customer. User exits, for example, have no defined interfaces, meaning all fields and tables are available to the developer. Therefore, any incorrect use of the available fields and tables can lead to undesired results.
It’s important for developers to explore alternatives before embarking on the implementation of any customer-defined routine or user exit. Developers must keep the checkpoints in mind that were laid out in the introduction of this chapter before proceeding with implementing an enhancement.
1.1 Enhancing Standard SD Functionality
SAP offers more than one method or technology to customize and enhance its off-the-shelf SD functionality. To give you an overview, Figure 1.1 shows a mind map of these methods and technologies. A flag indicates that the particular method is covered in this book.
As shown in the mind map, the main emphasis of this book is on exits, the Enhancement Framework, and customer-defined routines. This is not to say that all other techniques shown (Customizing, personalization, and business transaction events) are of no importance. However, in terms of custom code enhancements, these methods are not as relevant as exits, BAdIs, and customer-defined routines. Also, there are situations where modifications cannot be avoided (see Chapter 2 and Chapter 13 for details).
Figure 1.1 SD Enhancements Mind Map
In the following sections, we introduce exits, the Enhancement Framework, and customer-defined routines in more detail. This chapter will conclude with a comparison of enhancement techniques, which should help you make the right enhancement choice in your own projects.
1.1.1 Exits
Up to SAP release 4.6, exits were the only way to truly enhance SAP standard coding. (From release 4.6A onward, business add-ins (BAdIs) were introduced, which are discussed in Chapter 2, Section 2.3.)
SAP created exits when it developed the standard code and put these into places where customers need more flexibility. Exits are empty or inactive when delivered and can be completed by customers as needed. Exits provide the following advantages, especially when compared to modifications:
-
Developed objects do not affect standard coding and are held separately, in their own customer namespace.
-
During an upgrade project, most exits remain and do not affect the upgraded system (there are some exceptions, see the comparison tables in Section 1.4 of this chapter for details).
In the following sections, we’ll discuss the different types of exits and distinguish them by explaining their implementation and features.
More often than not, user exits and customer exits are mixed up or even regarded as the s...