Lesson 15. Display Variants for Line-item ReportsThis is the second of two lessons on customizing the layouts and contents of line-item reports. It deals with the procedures for creating and working with display variants. Line-item reports are the typical format for the output of list-display transactions, which generate lists of related objects (see the Coda at the end of this book) as well as the hit lists of code searches (see Lesson 10). They are also found on the initial and output screens of some create, display, and change transactions, including many purchasing and human resources transactions. Each row in a line-item report displays the data about a single object, such as a vehicle, material, or business expenditure. The data are arrayed in columns, which are capped by headers that identify the data, and the rows are usually organized vertically by default according to the contents of the first column. However, the content and layout of a line-item reportthe data it displays and the ways in which the data are arranged vertically and horizontallyare usually fixed by computer programmers, with the help of functional experts, when SAP is configured for your company. They may not necessarily meet your needs or interests as a user of the system. For example, we demonstrate the procedures for creating and working with display variants in this lesson with the output of the KSB1 transaction. This output consists of a line-item report of the actual costs or expenditures for a department (or cost center) in a business or an organization. We run this transaction periodically for our department to keep track of our costs and to monitor the status of our budget. The output of this transaction displays these data about our costs on each line of the report by default (Figure 15.1):
Figure 15.1. The default version of the output report of the KSB1 transaction.This is not an especially useful report for us, for several reasons.
To satisfy our business needs, we created a display variant for the output of the KSB1 transaction (Figure 15.2). This customized version of the line-item report displays these data for each cost:
Figure 15.2. Our display variant for the output report of the KSB1 transaction.In addition, we modified the layout of this line-item report to do the following:
This customized report is far more useful for our purposes, because it tells us in a nutshell who (by name and affiliation) spent our hard-earned money on what (by cost element name and document header text). In addition, it provides a document number that we can pass to our accountant in case we have questions about a charge to our account. Finally, it contains no data about offsetting accounts, currency type, or anything else that is either obvious or not of interest to us, so it is brief and to the point. Line-item reports are one of the most common transactions that are executed in SAP, and display variants are a powerful tool for customizing their contents and layouts. This lesson provides instructions on creating and using display variants. |