SAP Query Reporting

To create a basic report with the InfoSet (Ad Hoc) Query tool, follow these steps:

1.

Log in to the area of your SAP client where your query reports will be created. (Best practice dictates that you maintain query reports in your live production client.)

2.

You can access the InfoSet (Ad Hoc) Query tool in three ways:

  • Through an application-specific role, using the Easy Access menu

  • Via the SAP Query tool, by using transaction code SQ01 and then clicking the InfoSet Query button

  • Via transaction code /nPQAH

When you navigate to the InfoSet (Ad Hoc) Query tool main screen using any of these methods, you see a dialog box that prompts you to select your InfoSet (data source) from the designated environment (QUERY group).

3.

Select your InfoSet and then press Enter. The main screen of the InfoSet (Ad Hoc) Query tool appears, as shown in Figure 19.1.

Figure 19.1. The fields listed in the Field Groups section of the selected InfoSet appear on the top left of the InfoSet (Ad Hoc) Query screen.

The main screen of the InfoSet (Ad Hoc) Query tool has three sections:

  • The actual InfoSet from which you select and choose your fields (top left)

  • A Selections section (top right)

  • A sample report display (bottom)

4.

To create an InfoSet (Ad Hoc) Query report, select the check box in the Output column next to each field you want to include in the output of your report. For example, Figure 19.2 shows a few fields selected.

Figure 19.2. You will recognize the field groups from those created during configuration of the InfoSet.

5.

Notice that any field selected for layout is now displayed at the bottom of the screen (with bogus data) to assist you in seeing what your report will look like.

6.

Add fields to your Selections section (which functions as the report's selection screen) by selecting the appropriate check box in the Selection column next to each field you want to be able to select on (that is, specify) when executing your report. For example, Figure 19.3 shows one field selected.

Figure 19.3. The Selections section in InfoSet (Ad Hoc) Query tool reporting appears at the top right of the screen.

Any field(s) indicated for selection now appear on the top-right side of the screen. The Selections section works just as a standard selection screen works, allowing you to input values before execution to further specify your reporting output. (For example, you could specify to include only business class (Type C) flights in a report.)

7.

To proceed to your InfoSet (Ad Hoc) Query report output, click the Start Output button on the Application toolbar (or press the F8 key on your keyboard) to execute the report. By default, your report displays in the SAP List Viewer (previously known as the ABAP List Viewer [ALV]), from which you can easily drag and drop the columns and/or manipulate the look of the output (see Figure 19.4).

Figure 19.4. The SAP List Viewer view of the InfoSet (Ad Hoc) Query report is similar to the default report output shown for SAP Query tool reports.

Категории