Beruflich Dokumente
Kultur Dokumente
1.
1. 2. 3.
3.1.
TABLE OF CONTENTS
TABLE OF CONTENTS CHANGE HISTORY GENERAL
Analysis
2 3 4
4
4.
HOW-TO PROCEED
4.1. Create user group 4.1.1. Create user Group 4.2. 4.3. Create infoset Choose the Display-fields
5
5 5 6 8 8 9 10 11 12 12 13 16 16 17 18 18 21
4.4. Add additional fields 4.4.1. Add the fields 4.4.2. Add the code 4.5. Link infoset and user to user group
4.6. create the query 4.6.1. General 4.6.2. Output fields 4.6.3. Selection fields 4.6.4. Basic list layout 4.7. Link a transaction code to the query 4.7.1. Search program name 4.7.2. Link transaction code to query 4.8. Link hotspot
2.
CHANGE HISTORY
Date
Details
Author
Version
3.
3.1.
GENERAL
ANALYSIS
SAP (or ABAP) query can be used to generate reports on a rather simple way. This document is a very short manual on how-to create such a report. This document is not a complete manual, but rather a document that can be used as a guide.
4.
HOW-TO PROCEED
4.1. CREATE USER GROUP
A User group is needed to link certain users with the queries (which will be created later on) and generated reports. Transaction code : SQ03 Path : Tools ABAP Workbench- Utilities SAP query - SQ03
Fill in a description.
4.2.
CREATE INFOSET
Transaction code : SQ02 Path : Tools ABAP Workbench- Utilities SAP query - SQ02 There are two approaches to create an infoset : a. Infoset based on a logical database b. Infoset based on directly linked tables
a. Logical database Logical databases are special ABAP programs that retrieve data and make it available to application programs. A logical database provides a particular view of database tables in the R/3 System.
b. Linked tables. Use a table as head-table and link other tables afterwards.
First thing we have to do, is create the infoset. Fill in a name and click on create.
Fill in the data. For this example, well create a simple sales order list, so we take VBAK as table. This is the table with header data for sales orders. We take the option Table join using basis table because we will add other tables .
For the example, we add following tables : VBAP : table with sales order items. KNA1 : main data for customers VBPA : table with link between the sales order item and partner function
Click on BACK (green arrow). Mark the option Create empty field groups.
4.3.
On the left side, youll see the tables you have selected with all their fields. On the right side, youll see the already selected fields. You can add a field by dragging it from the left to the right. If necessary, change the column header from the field. When finished, click on save.
4.4.
Tpart-vtext is the field in the database which contains the long text for the partner function name
Go to record processing and add the code to read the added field.
4.5.
Transaction code : SQ03 Fill in your name from the user group, and click on assign users and infosets. Fill in the persons which are allowed to execute the query and infosets. After that, click on assign infosets
4.6.
4.6.1. General
Fill in the name and choose the infoset you want to use. Click on create. Fill in the needed info.
Click on next.
Select the field groups where there are fields which you want to show in the output
Click on next.
Click on next.
On the right, youll see an example of how the output will be. Save and exit.
4.7.
Fill in a short description and choose for program and selection screen
Fill in the program name. Mark the three options under SAP GUI.
4.8.
LINK HOTSPOT
You can link a transaction to the report which will open when you double-click on that line. Click on Go To -> Report Assignment
Click on Transaction