Chapter 2. One-Time Configuration for Query Tool Use

In this chapter

Steps in Configuring the Query Tools 12

Performing Maintenance on InfoSets 18

This chapter covers everything you need to know to make the SAP R/3 Query family of tools ready for use. The steps for the configuration are broken down in such a simple and easy-to-use format that anyone can perform them. However, the decision to use a particular tool or tools and the administrative methodology that will be put into place to use the tools requires deeper consideration.

Before you dive in and begin performing the one-time configuration that is necessary before you can use the SAP Query reporting tools, you should review Chapter 1, “Getting Started with the SAP R/3 Query Reporting Tools.” As discussed in Chapter 1, the SAP R/3 Query tools (SAP Query, InfoSet (Ad Hoc) Query, and QuickViewer) are built on a foundation of four main components:

• Query areas

• Query groups

• InfoSets

• Administrative decisions (which are company-specific)

This chapter covers how to configure query groups and InfoSets so that you can begin using the Query family of tools.

Steps in Configuring the Query Tools

After you have made the administrative decisions described in Chapter 1, you can perform the one-time configuration of the Query tools in four quick and easy steps:

1. Create query groups.

2. Assign users to query groups.

3. Create InfoSets.

4. Assign each InfoSet to a query group.

Step 1: Create Query Groups

A query group (known as a user group in versions of SAP prior to version 4.6) is a collection of SAP users who are grouped. The best way to think of query groups is to think of them along the lines of departments within an organization and the functional areas within those departments. For example, an organization’s Finance department may have multiple functional areas, including Accounts Payable, Accounts Receivable, Payroll, and so on. Creating user groups allows an organization to group its reporting users (and subsequently their reports) into functional areas. A user’s assignment to a query group determines which queries he or she can execute or maintain. Using query groups is an easy way to group and segregate your report users and reports.

To create a new query group, you perform the following steps:

1. Log in to your SAP client where your query groups will be maintained. (As noted in Chapter 1, best practice dictates that they be maintained in your live production client.)

2. Navigate to the User Groups: Initial screen by using the transaction code /nSQ03, as shown in Figure 2.1.

Figure 2.1. SAP query groups are created and modified using the User Groups: Initial screen.

Image

3. Ensure that you are in the appropriate query area by following the menu path Environment, Query Areas and selecting Standard Area. (Best practice dictates that you maintain query areas in the standard area, as discussed in Chapter 1.

4. Type in the name for your query group in the User Group field. (For purposes of this example, I’m naming mine ZTEST.) Then click the Create button.

5. When a dialog box appears, asking you to provide a description for your query group, type Test Query Group 1 and then click the green checkmark Save button.

Step 2: Assign Users to Your Query Groups

To assign users to a query group, perform the following steps:

1. Click the Assign Users and InfoSets button.

2. Type in the SAP user IDs of any users you wish to include in your test group, making sure to include your own user ID (see Figure 2.2).

Figure 2.2. Input the SAP user IDs for any user you wish to belong to the query group.

Image

3. Click the Save button on the toolbar. A message appears in your SAPGUI status bar, saying “User group ZTEST saved.”

Now that you have a query group created, the next step is to create an InfoSet.

Step 3: Create InfoSets

You create InfoSets (known as functional areas in versions of SAP prior to version 4.6) on the InfoSet: Initial screen, shown in Figure 2.3. As stated in Chapter 1, an InfoSet is basically the data source from which you get the data to use in your reports. You can picture an InfoSet as an organized container that holds all your stuff. InfoSets can be built on a variety of different sources, but the most common is the use of a logical database.

Figure 2.3. A list of all previously created InfoSets is displayed on the InfoSet: Initial screen.

Image

To create a new InfoSet, you perform the following steps:

1. Log in to your SAP client where your InfoSets will be maintained. (As noted in Chapter 1, best practice dictates that you maintain them in your development client.)

2. Navigate to the InfoSet: Initial screen by using the transaction code /nSQ02 (see Figure 2.3).

3. Ensure that you are in the appropriate query area by selecting Environment, Query Areas and then selecting Standard Area. (Best practice dictates that you maintain query areas in the standard area, as covered in Chapter 1.)

4. Type in a name for your InfoSet. (For purposes of this example, I’m naming mine ZTEST.) Then click the Create button.

5. On the InfoSet: Title and Database screen, type an InfoSet description in the Name field. (For purposes of this example, I’m naming mine Test InfoSet 1.)

6. On the InfoSet: Title and Database screen, select the Logical Database radio button and select or input logical database f1s in the field to its right (see Figure 2.4), and then press Enter.

Figure 2.4. There are several hundred logical databases to choose from.

Image


Helpful Hint

InfoSets can be created with various data sources, including logical databases, tables, table joins, and so on. The best business practice is to use the SAP-delivered logical databases as your data source. They have been created for this purpose, and at least one logical database is delivered with your system for each application area/module in SAP. The F1S logical database used in this example is the database that SAP uses in its training classes, which use a fictional airline scheduling system. It is best to use this for your test cases. If you have difficulty accessing this predelivered SAP test training solution, contact your system administrator, who can ensure that it was installed.


A Change InfoSet screen, similar to the one shown in Figure 2.5, appears. The Change InfoSet screen displays a list of all tables available in the selected logical database for your InfoSet. The logical database selected, F1S, contains three test tables, called SPFLI, SBOOK, and SFLIGHT, which correspond to the three field groups listed at the top right. The field groups are what the end users see when they are creating reports using the SAP Query reporting tool.

Figure 2.5. The Change InfoSet screen is divided into three sections.

Image

7. To view the fields in each of the three tables, use the expand subtree button next to each table name. The table selected expands and displays the fields underneath, as shown in Figure 2.6.

Figure 2.6. The left side of the screen lists the tables and fields, and the right displays the field groups.

Image

8. Assign fields to the field groups (shown on the top right of the screen) within the InfoSet. These field groups will display in the SAP Query tool during reporting. Only the fields that you include in your field groups will be available for field selection in the SAP Query tool that uses this InfoSet as its data source. By default, these field groups are empty.


Note

For all modules in SAP, by default, your field groups will be empty, and you will need to manually insert fields into them. This is true for all modules except for the Human Capital Management module and the InfoSets that support it. For those, the field groups will already be created for you, with a default set of fields; you can add additional fields, if required, as discussed in Chapter 15, “HR and Payroll Reporting Options in the HCM Module.”


9. Place your cursor on the first field group, Flight Schedule, and double-click to highlight that field group as the selected field group. Next, select fields from the left side of the screen from the Flight Schedule table and add them to the Flight Schedule field group by placing your cursor on a field on the left side of the screen, right-clicking, and selecting the option Add Field to Field Group (see Figure 2.7).

Figure 2.7. You should only add fields to their corresponding field groups (for example, Flight Schedule table to Flight Schedule field group).

Image

10. When the field you just added to the Flight Schedule field group appears at the top right of the screen, add fields to your selected functional group by following the procedure outlined in step 9. Be sure to add fields to the appropriate field groups. For example, fields in the Flight Schedule table should be added to the Flight Schedule field group, and fields from the Flight Booking table should be added to the Flight Booking field group.

11. After you have added a series of fields to your field groups, click the Save button on the toolbar. A message appears in the status bar, saying that your InfoSet was saved.

12. Generate the InfoSet by clicking the Generate button (the red beach ball) on the Application toolbar. A message appears in the status bar, saying that the InfoSet was generated.


Note

Clicking the Generate button for your InfoSet causes SAP to check whether any errors are present in the logic of the configuration of the InfoSet.


13. Exit the Change InfoSet screen by clicking the green back arrow.

Step 4: Assign Each InfoSet to a Query Group

You have now created a Query group, assigned users to it, and created an InfoSet. The last step before you begin creating reports is to assign your InfoSet to your Query group. This is an easy task:

1. On the InfoSet: Initial screen (which you reach by entering transaction code //nSQ02), make sure your InfoSet name (in my example, ZTEST) is present in the InfoSet text box, and click the User Group Assignment button.

2. In the InfoSet: Assign to User Groups screen that appears, highlight your query group (in my example, ZTEST) by selecting the gray button to the left of it, and then click the Save button. A message appears in the status bar, saying that the assignment of InfoSet has been saved.

3. Exit the InfoSet: Assign to User Groups screen by clicking the green Back arrow.

You are now ready to begin creating reports with the SAP R/3 Query reporting tools. Chapter 3, “Creating Basic Reports with the SAP Query Tool,” describes how to do so using SAP Query.

Performing Maintenance on InfoSets

The following sections provide details on maintenance functions that are available for InfoSets. These sections are designed to assist users who are responsible for the maintenance of InfoSets. Users who are being trained on the concepts of InfoSets need not review these maintenance functions. As recommended in Chapter 1, those designated personnel who will be responsible for the InfoSets can read on to see how to perform the different maintenance functions.

Returning to an InfoSet to Add Fields

After an InfoSet is created, you can return to it at any time to make changes. It is a best business practice to maintain an InfoSet in your development environment so any changes can be tested before the InfoSet is transported to your live production client. (See Chapter 1 for more information.)

To add an additional field to your InfoSet, follow these steps:

1. Log in to the SAP client where your InfoSets are maintained.

2. Navigate to the InfoSet: Initial Screen by using the transaction code /nSQ02.

3. Ensure that you are in the appropriate query area by selecting Environment, Query Areas and then selecting Standard Area.

4. Type in the name of the InfoSet that you want to make changes to, and then click the Change button.

5. Review the fields that are currently present in the field groups (shown on the top right of your screen) in your InfoSet.

6. When you initially created the InfoSet, it is likely that you did not add all fields in the logical database to your field groups. Determine which field group is the appropriate one to add a field to. Place your cursor on that field group, and double-click it to highlight it as the selected field group. Then select fields from the left side of the screen from the corresponding table and add them to the highlighted field group by placing your cursor on a field on the left side of the screen, right-clicking, and selecting the option Add Field to Field Group Remember to ensure that you add fields to the appropriate field group. Your newly added fields now appear in your selected field group.

7. When you have finished adding additional fields, click the Save button on the toolbar. A message appears in the status bar, saying that the InfoSet was saved.

8. Generate the InfoSet by clicking the Generate button on the Application toolbar. A message appears in the status bar, saying that the InfoSet has been generated.

Returning to an InfoSet to Delete Fields

After an InfoSet is created, you can return to it any time to remove fields. As mentioned earlier, it is a best business practice to maintain your InfoSet in your development environment so any changes can be tested before the InfoSet is transported to your live production client.

To delete a field from your InfoSet, follow these steps:

1. Log in to the SAP client where your InfoSets are maintained.

2. Navigate to the InfoSet: Initial screen by using the transaction code /nSQ02.

3. Ensure that you are in the appropriate query area by following the menu path Environment, Query Areas and selecting Standard Area.

4. Type in the InfoSet name and then click the Change button. The Change InfoSet screen appears, displaying a list of all the tables available in your InfoSet. The logical database F1S that is selected contains three test tables, called SPFLI, SBOOK, and SFLIGHT, which correspond to the three field groups listed at the top right.

5. To view the fields in each of the three tables, use the expand subtree button next to each table name. The table selected expands and displays the fields underneath.

6. Review the fields that are currently present in the field groups (shown on the top right of your screen) in your InfoSet.

7. Determine which field group you wish to delete fields from, and place your cursor on it. Double-click the field group to highlight it as the selected field group. Next, place your cursor on a field in the field group on the top-right side of the screen, right-click, and select the option Delete Field from Field Group. The deleted fields no longer appear in your selected field group.

8. When you have finished deleting fields, click the Save button on the toolbar. A message appears in the status bar, saying that InfoSet was saved.

9. Generate the InfoSet by clicking the Generate button on the Application toolbar. A message appears in the status bar, saying that the InfoSet has been generated.


Note

If you selected to remove fields that are already used in existing queries, you will receive an error message saying “Field used in existing query.” A best practice is to first determine whether the field is in use. You do so by placing your cursor on the field, right-clicking, and selecting the Queries for Field option. SAP then displays a list containing any existing queries that use that field. You need to access that query and remove the field from its output before you can save the changes to your InfoSet.


Changing the Name of a Field or Column Header

Many users will be looking for a field name that corresponds to a field name on an SAP screen, so it is important to be very careful when renaming fields and column headers. However, there are rare situations in which you may need to do so. You can alter the name of a field and its column heading when it appears in a query-based report by simply following these steps:

1. Select a field by double-clicking it in the top-right side of the screen. The details of that field appear on the bottom-right side of the screen, as shown in Figure 2.8.

Figure 2.8. It is not a best practice to rename fields.

Image

2. Alter the field name by editing the text in the Long Text field, and edit the column heading of the field as it will appear in reports by editing the text in the second line of the Header field at the bottom right, as highlighted in Figure 2.8.

3. Click the Save button on the toolbar. A message appears in the status bar, saying that the InfoSet was saved.

4. Generate the InfoSet by clicking the Generate button from the Application toolbar. A message appears in the status bar, saying that the InfoSet has been generated.

Reverting the Name of a Field or Column Header to Its Original Name

If you have altered the name of a field or column heading, you can revert it to the SAP standard delivered text by following these steps:

1. Select a field by double-clicking it in the top-right side of the screen. The details of that field appear on the bottom-right side of the screen.

2. Click the Get Default button. The field and column names revert to their original names.

3. Click the Save button on the toolbar. A message appears in the status bar, saying that the InfoSet was saved.

4. Generate the InfoSet by clicking the Generate button on the Application toolbar. A message appears in the status bar, saying that the InfoSet has been generated.

Things to Remember

• Configuring the SAP Query tools is very easy.

• You should use your company’s standard naming convention when you perform this configuration at your organization.

• Be sure to add your own user ID to your newly created query group.

• You should add fields to corresponding field groups when building an InfoSet.

• Use caution when renaming fields or column headings to ensure that your end users will be able to recognize the fields.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.144.90.182