当前位置:网站首页>SAP ABAP report programming-08
SAP ABAP report programming-08
2022-06-22 16:21:00 【Boating in rainy days】
SAP ABAP Report programming -08
SAP-ABAP Two types of programs are supported - Reporting procedures and dialogue procedures . report form The program uses... When it needs to display a large amount of data
In this tutorial , You will learn :
- Select screen
- ABAP Report planned events
- Format report
- Interactive report programming
- Logical database
The purpose of the reporting procedure / purpose
- When data from multiple tables must be selected and processed before rendering , They will be used
- Use... When a report requires a special format
- When the report must be transferred from SAP Download to the to be distributed Excel Use... When working with worksheets .
- Use when the report must be mailed to a specific person .
Notes on reporting procedures
- The reporter is always an executable program . The program type is always 1.
- Each reporter corresponds to a specific application type , Sales and distribution ,FI - CO etc. . It can also be cross application , That is, type “*”.
- Report programming is an event driven programming .
- The first line of the reporter is always the report *< Report name >.*
- To suppress the display of list titles or program names , Please use add *“ No standard page title *”.
- You can use the addition line size < size > To set up a specific report Line size of .
- You can use the addition line count n(n1) To set the row count for a particular page .N Is the number of lines on the page ,N1 Is the number of rows reserved for the page footer .
- To display any information or error messages , We use the added add Add a message class to the program in :Message-id<message Class name >. The mail class is in SE91 In the maintenance .
therefore , The ideal reporting process should begin with :
Report <report name> no standard page heading
line-size <size>
line-count <n(n1)>
message-id <message class>.
Select screen
Select screen ” Is a screen that specifies the input values that the program should run .
The selection screen usually starts from
- Parameters
- choice - Options
grammar
Selection-screen begin of screen <screen #>
selection-screen begin of block <#> with frame title <text>
.........
.........
selection-screen end of block <#>
selection-screen end of screen <screen #>
Parameters
Parameters help with dynamic selection . They can only hold one value for one execution cycle of the program .
grammar
Define parameters as data types
Parameters p_id(30) type c.
Defining parameters , As shown in the table .
Parameter p_id like <table name>-<field name>.
The parameter can be a check box , It can also be a radio button .
Parameters p_id as checkbox.Parameters p_id1 radiobutton group <group name>.
Parameters p_id2 radiobutton group <group name>.
The parameter can be a list box .
Parameter p_id like <table name>-<field name> as listbox
Select options
The selection option is used to enter a series of values or a set of values into the program
grammar
select-options s_vbeln for vbak-vbeln.

You can also define a selection option , Such as variable
select-options s_vbeln for vbak-vbeln no intervals no-extension
ABAP Report planned events
ABAP The reporting procedure is Event driven programs . Different events in the report Program Include :
Program loading
- The load type is 1、M、F or S After , Trigger the associated event in the internal session .
- Run the associated processing block once for each program and internal session at the same time , And only run once .
- For types of 1、M、F or S Of ABAP Program , Processing block LOAD-OF-PROGRAM Functions and constructors of for ABAP Classes in the object have roughly the same functions
initialization .
- This event is executed before the selection screen is displayed .
- Initialize all values .
- You can specify values other than the default values on the selection screen .
- You can fill the selection screen with some values at run time .
On the selection screen .
- When processing the selection screen ( stay PAI At the end of ) Deal with the incident .
- The validation and check of input values are performed here
Start choosing .
- ad locum , The program starts selecting values from the table .
Choose the end .
- After selecting all data , This event writes data to the screen .
Interactive activities
- For interactive reporting . It is used to create detailed lists from basic lists .
Format report
ABAP It is allowed to set the format of the report to the format desired by the user . for example ,“ Alternate row ” Must be displayed in different colors ,“ A total of ” Lines should be displayed in yellow .
grammar
Format Color n
Format Color n Intensified On
n It can correspond to various numbers
Please note that , Besides the format , There are other additions
FORMAT COLOR OFF INTENSIFIED OFF INVERSE OFF HOTSPOT OFF INPUT OFF
Interactive report programming
- Use interactive programming , Users can actively control the retrieval and display of data
- Used to create detailed lists from very basic lists
- The detailed data is written in the auxiliary list .
- The auxiliary list can completely cover the first screen , It can also be displayed in a new screen
- The auxiliary list itself can be interactive .
- The first list can also invoke transactions .
- There are different events associated with interactive programming .
Some commands for interactive programming
hotspot
If you drag the mouse over the data displayed in the report , The cursor changes to “ Hold out your index finger ” hand . have access to FORMAT Statement implementation hotspot .
Syntax: Format Hotspot On (Off).
hide
This command helps you store field names based on field names that will be processed further , For a detailed list . It is written directly in the field WRITE After statement . When selecting rows , Values are automatically populated into variables for further use .
Syntax: Hide <field-name>.
Logical database
- You can use a logical database to retrieve program data , Instead of using “ choice ” Inquire about .
- The logical database consists of transactions SE36 establish
- The name of a logical database can contain at most 20 Characters . It may start with a namespace prefix .
- The data is selected by another program , have access to GET Command access data , This command places the data in the workspace .
Logical database is relative to common database Select Advantages of query .
- It provides inspection conditions , To see if the input is correct , Complete and reasonable
- It contains a central authorization check for database access
- Performance improvements and other enhancements are immediately applied to all reports that use a logical database .
notes : Due to the complexity involved , In most cases, logical databases are not used
Reference resources :https://www.guru99.com/all-about-abap-report-programming.html
边栏推荐
猜你喜欢

ironSource Luna 推出苹果搜索广告限时优惠,注册即享3个月免费服务

The odoo system sets priorities for the views independently developed by the original model

shell学习
New design of databend SQL planner

数睿数据受邀参与南通企业数字化转型研讨会

实现一个Container全局组件步骤(给还不会使用组件的新手一个思路,大佬绕道)

SAP abap 数据类型,操作符和编辑器-02

How to embody the value of knowledge management in business

Simulation of vector

Process address space
随机推荐
Luogu p2466 [sdoi2008] Sue's small ball solution
webDriver以及Selenium使用总结
Huawei cloud hcdez special session and Distributed Technology Summit: Huawei cloud distributed cloud native technology and Practice
nio编程service
[VTK] model rotation and Translation
使用枚举实现工厂模式
使用stream api替代sql
SAP ABAP 中的 Smart Forms-014
用递归法求Fibonacci数列第n项的值
着力打造网红产品,新捷途X70S焕新上市,8.79万起售
B树和B+树
Gd32f4xx MCU drives MCP2515 to expand can interface
预约打新债到底安不安全呀?是不是靠谱的?
在JFlash中添加未知类型的单片机
3.抽象類(shape)
What is the relationship between CSC securities and qiniu school? Is it safe to open a securities account
Modularity in SAP ABAP: macros, subroutines and function modules -04
Dear students, don't read the textbooks any more. Just read this one for the complexity of time
odoo本地文档功能开发记录
19、 Xv6 context switching (implementation of context switching; encapsulation and recovery of state machine)