Sap Abap Reports Questions
Sap Abap Reports Questions
Abap
Reports
Ques ons
Sonu Jangir Abap Developer
Report is a program used to fetch data from the database tables and
display it on the screen. It has 2 screens selec on screen(op onal)
and list or output screen.
SKIP generates a blank line, while the NEW-LINE causes the control to
move to next line.
What is hotspot?
Hotspot is an area on the list where the mouse pointer turns into an
upright hand symbol. A single click on the hotspot does the same
thing as a double-click.
INITIALIZATION
AT SELECTION-SCREEN
START-OF-SELECTION
END-OF-SELECTION
TOP-OF-PAGE
END-OF-PAGE
20
What is the name of the system variable that holds the contents of
the selected line in interac ve repor ng?
SY-LISEL
What Is Alv?
ALV (ABAP LIST VIEWER) Sap provides a set ofALV (ABAP LIST
VIEWER) func on modules, which can be put into use to embellish
the output of a report. This set of ALV func ons is used to enhance
the readability and func onality of any report output.
Prepared By Sonu Jangir +91 9729751248
[email protected]
Or
ALV stands for ABAP List Viewer. ALV gives us a standard List format
and user interface to all our ABAP reports. ALV is created by a set of
standard func on modules provided by SAP.
Sor ng of records
Filtering of records
Totals and Sub-totals
Download the report output to Excel/HTML
Changing the order of the columns in the report
Hide the unwanted columns from the report
The user can programma cally set the ini al (default) variant for list
display.
The default variant can be found using the func on module
'REUSE_ALV_VARIANT_DEFAULT_GET'.
What Is The Events Table In Alv?
Totals
Interac on
Detail screen
Color
Other
Group: '* ' = new page at group value change ,'UL' = underline
REUSE_ALV_GRID_DISPLAY
What Is A Report?
These are the most simple reports. Programmers learn this one first.
It is just an output of data using the Write statement inside a loop.
Classical reports are normal reports. These reports are not having any
sub reports. IT IS HAVING ONLY ONE SCREEN/LIST FOR OUTPUT.
AT LINE-SELECTION
AT USER-COMMAND
AT PF<key>
TOP-OF-PAGE DURING LINE-SELECTION.
HIDE statement holds the data to be displayed in the secondary list.
sy-lisel : contains data of the selected line.
sy-lsind : contains the level of report (from 0 to 21)
How Many Types Of Tables Are There In Data Dic onary And What
They?
Transparent table
Pricing Tables starts with A* like A001, A002, A900 like that.
KONH – Condi on Header
KONP – Condi on Detail
If you have MANDT as the first field that is Client Dependant table
otherwise it is not. Usually most of the tables are client dependent.
Only few like RFC Connec ons table (RFCDES), Batch Jobs (TBTCO and
TBTCP) are not client dependant.
Create a variant in the ALV Report with whatever columns you would
like to see and set sort criteria and column widths and save as a
default variant.
You could get the default variant by calling FM
REUSE_ALV_VARIANT_DEFAULT_GET
Create all the Domains and Data elements as needed using Txn SE11.
Start crea ng the table using Tcode SE11.
Maintain Delivery Class (A-Applica on Table, C-Customizing, etc)
Enter all the fields (MANDT must be the first field) and appropriate
data elements or Built in Types for each field.
Make sure you select the Primary Key for this table.
Maintain the Technical Se ngs (Data class, Size, Buffering info)
Create Secondary indexes as needed
Prepared By Sonu Jangir +91 9729751248
[email protected]
Ac vate the Table
In the Field Catalog table, you set the HOTSPOT property of the field
to X.
Using this func on module, you can get the Field catalog for a given
Internal table or DD Structure. Once you get the Field catalog, you
could change the proper es of each field.
What Is Significance Of Hide?
SELECT SINGLE can be used if you know the full key to select a record.
If you do not have the full Key to select and you are interested in one
single row, you could use SELECT UPTO 1 ROWS. If you use a SELECT
SINGLE without a full key, you would get a warning message in
Extended Program checks.
If you have the full Key use SELECT SINGLE
If you do not have the full Key to select and you are interested in one
single row, you could use SELECT UPTO 1 ROWS..
ABAP memory is a memory area that all ABAP programs within the
same internal session can access using the EXPORT and IMPORT
statements.
SAP memory is a memory area to which all main sessions within a
SAPgui have access. You can use SAP memory either to pass data
from one program to another within a session, or to pass data from
one session to another. Applica on programs that use SAP memory
must do so using SPA/GPA parameters (also known as SET/GET
parameters).
SKIP generates a blank line, while the NEW-LINE causes the control to
move to next line.
SAP provides support in the form of Notes also and this is called OSS.
Can check the link Sree provided.
Just for an example if you face any error in your system. Then there is
error number associated with the error. Then you can search for the
OSS not for the error number, and the note will give you possible
solu on to your problem.
How Can Validate Input Values In Selec on Screen And Which Event
Was Fired?
Internal table with header line is nothing but work area name as well
as internal table name is same, whereas internal table without
header line is nothing but work area name as well as internal table
name is different.
FOR INTERNAL TABLE WITH HEADER we need not create work area.
But not advisable because the user may get confused what is work
area and what is internal table since they both will be having same
names.
While Prin ng, 10 Columns Are Prin ng In First Page And The Next
4 Cols In Next Page, How Do U Resolve This To Accommodate All
The 14 Columns In A Single Page?
Report dont need any event to execute the output.It we we put start-
of-selec on there is no compulsory to use end-of-selec on. End-of-
selec on is used when we want to execute some output even when
some excep on occurs to skip start-of-selec on.
Prepared By Sonu Jangir +91 9729751248
[email protected]
There is no mandatory event in the report program. however, if we
don't explicitly write any event, system implicitly starts with start of
selec on event.In case of database selec on, it is a good prac ce of
use end-of-selec on event.
Check table works at table level and value table works at domain
level.
Check table is nothing but master table that u will create with valid
set of values.
Value table it provides the list of values and it will automa cally
proposed as a check table while crea ng foreign key rela onship.
When It’s The Right Time To U lize The Command Get Cursor In
Interac ve Lists?
The start and the finish of the main processing logic, which is default
for every ABAP/4 applica on; the statements from START-OF-
SELECTION to END-OF-SELECTION are executed automa cally, there
is no requirement for having END-OF-SELECTION. Every procedural
statement in ABAP applica ons are dependent by default on the
START-OF-SELECTION.
Reports use SELECT queries for database access. There are also
buffering techniques for faster access to frequently used data.
By using pagina on, limi ng the data fetched using SELECT op ons,
and leveraging parallel processing.
The HIDE statement stores field values for later use when the user
interacts with the report (e.g., clicking a line triggers detailed views).
What are Field Symbols, and how are they used in reports?
Field symbols are placeholders for data objects. They point to data
instead of copying it, which op mizes memory usage in reports.
A hotspot allows for clickable fields in the output list that trigger
addi onal events, such as naviga ng to detailed informa on.
What was the most complex report you’ve worked on, and how did
you approach it?
Prepared By Sonu Jangir +91 9729751248
[email protected]
Provide an example of a report with complex logic, discussing how
you op mized performance, managed data volumes, and ensured
user interac vity.
).
lt_filtered_customers = FILTER #( lt_customers WHERE country =
'Germany' ).
Now that we've covered the key aspects of reports in SAP ABAP as
part of the RICEFW framework, let’s move on to Interfaces, another
cri cal component for seamless data exchange between SAP and
external systems.
EQ
If we are passing only a low value and High value in Select-op on,
what is the rela onal operator?
BT
Types of user exists, what kind of work is done on these exists ?
How will you find out where the user exits are available?