Enhancing Supply Chain Visibility with Cargo Cloud Solutions.pdf
SAP SD QUERY REPORT_GANESH
1. SAP QUERY REPORT FOR ALL FUNCTIONAL
CONSULTANTS
1 | P a g e
C R E A T E D B Y
G A N E S . T A R L A N A
S A P S D
Introduction about SAP QUERY:
The SAP Query application is used to create reports not already contained in the
default. It has been designed for users with little or no knowledge of the SAP
programming language ABAP.
SAP Query offers users a broad range of ways to define reports and create different
types of reports such as basic lists, statistics, and ranked lists.
The whole process comprises of three steps..
Creation of user group
Creation of info set
Creation of queries
The transaction codes associated with ABAP Query are
SQ03 – User Group
SQ02 - Info set
SQ01 – SAP Query
Step-1: SQ03---USERGROUP CREATION
The technical definition of “User Groups” is a collection of SAP users who are
grouped together.
A user’s assignment to a user group determines which queries he or she can
execute or maintain. Additionally, it designates which Info Sets the user can access
Basically, Query Groups permit users to create, modify, and execute reports in a
certain area within R/3.
The relationship b/w user group and Info set is one to many.
One user group can be assigned to no. of Info sets, in which users are placed.
2. SAP QUERY REPORT FOR ALL FUNCTIONAL
CONSULTANTS
2 | P a g e
C R E A T E D B Y
G A N E S . T A R L A N A
S A P S D
SAP QUERY REPORT CONFIGURATION
Mention User Group Name and click create
Mention short text name and save it.
Assign Users in User group
Save it again.
Step-2: SQ02--.INFOSET CREATION
An Info Sec describes which fields of a data source can be reported on in queries.
1. Mention info set and Click create
3. SAP QUERY REPORT FOR ALL FUNCTIONAL
CONSULTANTS
3 | P a g e
C R E A T E D B Y
G A N E S . T A R L A N A
S A P S D
2.Mention Info set name
Data source
TABLE JOIN : Multiple tables (VBAK,VBAP,LIKP,LIPS,VBRK,VBRP)
DIRECT READ TABLE: Single Table VBAK
Select Table join and Press Enter then system show Navigation Screen
4. SAP QUERY REPORT FOR ALL FUNCTIONAL
CONSULTANTS
4 | P a g e
C R E A T E D B Y
G A N E S . T A R L A N A
S A P S D
If you want to add other tables click Insert Table then Click the JOIN
Conditions and then click Info set Maintain
System gives one pop with following options
A. include all tables fields: All fields
If you select first one system takes all the fields from selected tables.
Example: it is for your understanding
Sales Header Data VBAK
5. SAP QUERY REPORT FOR ALL FUNCTIONAL
CONSULTANTS
5 | P a g e
C R E A T E D B Y
G A N E S . T A R L A N A
S A P S D
Sales Item Data VBAP
B. Key fields for user specific: System taken default fields
S.NO FIELDS
1 Sales document
2 Sales document item
3 Material Number
C.Create empty field group: Add user specific Fields
1. Two empty field groups got created. In the left pane, we find the list of
fields in both the tables VBAK and VBAP.
6. SAP QUERY REPORT FOR ALL FUNCTIONAL
CONSULTANTS
6 | P a g e
C R E A T E D B Y
G A N E S . T A R L A N A
S A P S D
2.Drag and drop the fields from the left pane on to the field groups
Click save button system gives one pop up screen
Package or Local object both are optional.
7. SAP QUERY REPORT FOR ALL FUNCTIONAL
CONSULTANTS
7 | P a g e
C R E A T E D B Y
G A N E S . T A R L A N A
S A P S D
click Generate Button after Save Infoset.
ASSIGNEMENT OF INFOSET TO USERGROUP
Go to Info set and click Role/user assignment
Select our user group and save it.
Note: when we save the info set it’s automatically assign to our user
group.
Next step continuous in next page
8. SAP QUERY REPORT FOR ALL FUNCTIONAL
CONSULTANTS
8 | P a g e
C R E A T E D B Y
G A N E S . T A R L A N A
S A P S D
Step-3: SQ01----SAP QUERY REPORT CREATION
Create SAP QUERY
Enter query name (our own name) and Click create button then system open
another screen. Please observe below screen.
9. SAP QUERY REPORT FOR ALL FUNCTIONAL
CONSULTANTS
9 | P a g e
C R E A T E D B Y
G A N E S . T A R L A N A
S A P S D
Next screen will open
10. SAP QUERY REPORT FOR ALL FUNCTIONAL
CONSULTANTS
10 | P a g e
C R E A T E D B Y
G A N E S . T A R L A N A
S A P S D
a) ENTER Query title name
b) Select output format
SAP provides different types of report output for user specific.
c) Click Basic List then system will open layout design.
11. SAP QUERY REPORT FOR ALL FUNCTIONAL
CONSULTANTS
11 | P a g e
C R E A T E D B Y
G A N E S . T A R L A N A
S A P S D
The below screen is showing report layout design
Select Table and drag all the fields
System shows our selected tables, List fields, Selection fields.
1. List Fields means Output fields
12. SAP QUERY REPORT FOR ALL FUNCTIONAL
CONSULTANTS
12 | P a g e
C R E A T E D B Y
G A N E S . T A R L A N A
S A P S D
2. Selection Fields means Input Fields.
Select output list fields and Input Fields from our selected tables then click Test
button.
After above step click the test and System open report input screen
Enter our input data and Execute (Press F8) then system is shows our designed
simple report.
Please observe below screen.
13. SAP QUERY REPORT FOR ALL FUNCTIONAL
CONSULTANTS
13 | P a g e
C R E A T E D B Y
G A N E S . T A R L A N A
S A P S D
This is SAP Query report output.
The below step Explains query and user specific transaction report and in this step
integration will be there B/W Functional consultants (FI, SD, MM, PP etc.…) and
Technical consultants (ABAP).
Step-4 Maintain user specific transaction (ABAPER WILL DO THIS STEP)
Go to SE93
Create new transaction YQ01
Mention short text name
Select Parameter transaction and press enter
Maintain default transaction START_REPORT
[*] Skip initial screen
14. SAP QUERY REPORT FOR ALL FUNCTIONAL
CONSULTANTS
14 | P a g e
C R E A T E D B Y
G A N E S . T A R L A N A
S A P S D
Maintain default values in SE93
Note: The below parameters are mandatory for any query report
Name of screen field Values
D_SREPOVARI-REPORTTYPE AQ
D_SREPOVARI-EXTDREPORT SAP QUERY NAME(Z_QUERY_SALES)
D_SREPOVARI-REPORT USER-GROUPNAME(Z_USEER_GROUP)
Click the TEST Button .
If success, then save it.
Now execute YQ01 Transaction.
Give your input data and Execute
System will show user specific simple report.
User specific report -1
15. SAP QUERY REPORT FOR ALL FUNCTIONAL
CONSULTANTS
15 | P a g e
C R E A T E D B Y
G A N E S . T A R L A N A
S A P S D
User specific report -2
1. Requirement: I want to see Sales report, sales organization wise with
diagrammatically.
Output Format
16. SAP QUERY REPORT FOR ALL FUNCTIONAL
CONSULTANTS
16 | P a g e
C R E A T E D B Y
G A N E S . T A R L A N A
S A P S D
SALES
DOC
SALES
DOCTYPE
SALES
ORG
DISTRI.CHANNEL DIVISION SALES
OFFICE
CUSTOMER Net
value
Plant
This is SAP QUERY REPORT.
THE END