- 浏览: 230774 次
- 性别:
- 来自: 大连
文章分类
最新评论
-
evangxli:
niitallen 写道为啥我就显示不出来数据呢,在smart ...
ALV & SMARTFORMS 并分页 -
niitallen:
为啥我就显示不出来数据呢,在smartforms中~~
ALV & SMARTFORMS 并分页 -
binjoo:
insufficient privileges -
695165987:
用逗号分割,是改变那个参数。
SAP Function module - GUI_DOWNLOAD -
shamusoft:
希望你成功
四月咯
转自: Barry 白
1、最普通的用法
*Code used to execute a report
SUBMIT Zreport.
2、带select-options程序的Submit的用法
*Code used to populate 'select-options' & execute report
DATA: seltab type table of rsparams,
seltab_wa like line of seltab.
seltab_wa-selname = 'PNPPERNR'.
seltab_wa-sign = 'I'.
seltab_wa-option = 'EQ'.
* load each personnel number accessed from the structure into
* parameters to be used in the report
loop at pnppernr.
seltab_wa-low = pnppernr-low.
append seltab_wa to seltab.
endloop.
SUBMIT zreport with selection-table seltab
via selection-screen.
3、带parameters程序的Submit的用法
*Code used to populate 'parameters' & execute report
SUBMIT zreport with p_param1 = 'value'
with p_param2 = 'value'.
4、其他情况
*Submit report and return to current program afterwards
SUBMIT zreport AND RETURN.
*Submit report via its own selection screen
SUBMIT zreport VIA SELECTION-SCREEN.
*Submit report using selection screen variant
SUBMIT zreport USING SELECTION-SET 'VARIANT1'.
*Submit report but export resultant list to memory, rather than
[color=blue]*it being displayed on screen[/color]
SUBMIT zreport EXPORTING LIST TO MEMORY.
* Once report has finished and control has returned to calling
* program, use function modules LIST_FROM_MEMORY, WRITE_LIST and
* DISPLAY_LIST to retrieve and display report.
*Example Code (Retrieving list from memory)
DATA BEGIN OF itab_list OCCURS 0.
INCLUDE STRUCTURE abaplist.
DATA END OF itab_list.
DATA: BEGIN OF vlist OCCURS 0,
filler1(01) TYPE c,
field1(06) TYPE c,
filler(08) TYPE c,
field2(10) TYPE c,
filler3(01) TYPE c,
field3(10) TYPE c,
filler4(01) TYPE c,
field4(3) TYPE c,
filler5(02) TYPE c,
field5(15) TYPE c,
filler6(02) TYPE c,
field6(30) TYPE c,
filler7(43) TYPE c,
field7(10) TYPE c,
END OF vlist.
SUBMIT zreport EXPORTING LIST TO MEMORY.
CALL FUNCTION 'LIST_FROM_MEMORY'
TABLES
listobject = itab_list
EXCEPTIONS
not_found = 4
OTHERS = 8.
CALL FUNCTION 'LIST_TO_ASCI'
EXPORTING
list_index = -1
TABLES
listasci = vlist
listobject = itab_list
EXCEPTIONS
empty_list = 1
list_index_invalid = 2
OTHERS = 3.
IF sy-subrc NE '0'.
WRITE:/ 'LIST_TO_ASCI error !! ', sy-subrc.
ENDIF.
5、Submit为后台执行
*Submit report as job(i.e. in background)
data: jobname like tbtcjob-jobname value
' TRANSFER TRANSLATION'.
data: jobcount like tbtcjob-jobcount,
host like msxxlist-host.
data: begin of starttime.
include structure tbtcstrt.
data: end of starttime.
data: starttimeimmediate like btch0000-char1.
* Job open
call function 'JOB_OPEN'
exporting
delanfrep = ' '
jobgroup = ' '
jobname = jobname
sdlstrtdt = sy-datum
sdlstrttm = sy-uzeit
importing
jobcount = jobcount
exceptions
cant_create_job = 01
invalid_job_data = 02
jobname_missing = 03.
if sy-subrc ne 0.
"error processing
endif.
* Insert process into job
SUBMIT zreport and return
with p_param1 = 'value'
with p_param2 = 'value'
user sy-uname
via job jobname
number jobcount.
if sy-subrc > 0.
"error processing
endif.
* Close job
starttime-sdlstrtdt = sy-datum + 1.
starttime-sdlstrttm = '220000'.
call function 'JOB_CLOSE'
exporting
event_id = starttime-eventid
event_param = starttime-eventparm
event_periodic = starttime-periodic
jobcount = jobcount
jobname = jobname
laststrtdt = starttime-laststrtdt
laststrttm = starttime-laststrttm
prddays = 1
prdhours = 0
prdmins = 0
prdmonths = 0
prdweeks = 0
sdlstrtdt = starttime-sdlstrtdt
sdlstrttm = starttime-sdlstrttm
strtimmed = starttimeimmediate
targetsystem = host
exceptions
cant_start_immediate = 01
invalid_startdate = 02
jobname_missing = 03
job_close_failed = 04
job_nosteps = 05
job_notex = 06
lock_failed = 07
others = 99.
if sy-subrc eq 0.
"error processing
endif.
SUBMIT的几种情况
1、最普通的用法
*Code used to execute a report
SUBMIT Zreport.
2、带select-options程序的Submit的用法
*Code used to populate 'select-options' & execute report
DATA: seltab type table of rsparams,
seltab_wa like line of seltab.
seltab_wa-selname = 'PNPPERNR'.
seltab_wa-sign = 'I'.
seltab_wa-option = 'EQ'.
* load each personnel number accessed from the structure into
* parameters to be used in the report
loop at pnppernr.
seltab_wa-low = pnppernr-low.
append seltab_wa to seltab.
endloop.
SUBMIT zreport with selection-table seltab
via selection-screen.
3、带parameters程序的Submit的用法
*Code used to populate 'parameters' & execute report
SUBMIT zreport with p_param1 = 'value'
with p_param2 = 'value'.
4、其他情况
*Submit report and return to current program afterwards
SUBMIT zreport AND RETURN.
*Submit report via its own selection screen
SUBMIT zreport VIA SELECTION-SCREEN.
*Submit report using selection screen variant
SUBMIT zreport USING SELECTION-SET 'VARIANT1'.
*Submit report but export resultant list to memory, rather than
[color=blue]*it being displayed on screen[/color]
SUBMIT zreport EXPORTING LIST TO MEMORY.
* Once report has finished and control has returned to calling
* program, use function modules LIST_FROM_MEMORY, WRITE_LIST and
* DISPLAY_LIST to retrieve and display report.
*Example Code (Retrieving list from memory)
DATA BEGIN OF itab_list OCCURS 0.
INCLUDE STRUCTURE abaplist.
DATA END OF itab_list.
DATA: BEGIN OF vlist OCCURS 0,
filler1(01) TYPE c,
field1(06) TYPE c,
filler(08) TYPE c,
field2(10) TYPE c,
filler3(01) TYPE c,
field3(10) TYPE c,
filler4(01) TYPE c,
field4(3) TYPE c,
filler5(02) TYPE c,
field5(15) TYPE c,
filler6(02) TYPE c,
field6(30) TYPE c,
filler7(43) TYPE c,
field7(10) TYPE c,
END OF vlist.
SUBMIT zreport EXPORTING LIST TO MEMORY.
CALL FUNCTION 'LIST_FROM_MEMORY'
TABLES
listobject = itab_list
EXCEPTIONS
not_found = 4
OTHERS = 8.
CALL FUNCTION 'LIST_TO_ASCI'
EXPORTING
list_index = -1
TABLES
listasci = vlist
listobject = itab_list
EXCEPTIONS
empty_list = 1
list_index_invalid = 2
OTHERS = 3.
IF sy-subrc NE '0'.
WRITE:/ 'LIST_TO_ASCI error !! ', sy-subrc.
ENDIF.
5、Submit为后台执行
*Submit report as job(i.e. in background)
data: jobname like tbtcjob-jobname value
' TRANSFER TRANSLATION'.
data: jobcount like tbtcjob-jobcount,
host like msxxlist-host.
data: begin of starttime.
include structure tbtcstrt.
data: end of starttime.
data: starttimeimmediate like btch0000-char1.
* Job open
call function 'JOB_OPEN'
exporting
delanfrep = ' '
jobgroup = ' '
jobname = jobname
sdlstrtdt = sy-datum
sdlstrttm = sy-uzeit
importing
jobcount = jobcount
exceptions
cant_create_job = 01
invalid_job_data = 02
jobname_missing = 03.
if sy-subrc ne 0.
"error processing
endif.
* Insert process into job
SUBMIT zreport and return
with p_param1 = 'value'
with p_param2 = 'value'
user sy-uname
via job jobname
number jobcount.
if sy-subrc > 0.
"error processing
endif.
* Close job
starttime-sdlstrtdt = sy-datum + 1.
starttime-sdlstrttm = '220000'.
call function 'JOB_CLOSE'
exporting
event_id = starttime-eventid
event_param = starttime-eventparm
event_periodic = starttime-periodic
jobcount = jobcount
jobname = jobname
laststrtdt = starttime-laststrtdt
laststrttm = starttime-laststrttm
prddays = 1
prdhours = 0
prdmins = 0
prdmonths = 0
prdweeks = 0
sdlstrtdt = starttime-sdlstrtdt
sdlstrttm = starttime-sdlstrttm
strtimmed = starttimeimmediate
targetsystem = host
exceptions
cant_start_immediate = 01
invalid_startdate = 02
jobname_missing = 03
job_close_failed = 04
job_nosteps = 05
job_notex = 06
lock_failed = 07
others = 99.
if sy-subrc eq 0.
"error processing
endif.
发表评论
-
SAP 常用的库存表
2018-11-24 09:58 4864根据库存类型的不同,库存信息保存在不同的表中 ... -
SE16N变更为编辑模式
2018-09-19 10:27 2238SAP中直接修改表、视图的Tcode有SE16N和SM30。 ... -
SAP 示例
2018-07-11 13:08 1236经常会用到一些SAP自带的小程序, 无TCODE, 或者是 ... -
ABAP Test Cockpit (ATC) - About the TCode
2014-11-28 09:24 2784ABAP测试驾驶舱这个翻译很牵强,姑且叫做ABAPer 的诊 ... -
SAP SmartForms 字符处理
2014-05-14 14:44 2057格式化数字等,在smartforms显示输出的格式。 ... -
adf
2013-09-10 17:07 0*&------------------------ ... -
SAP Code 增强
2013-09-23 14:06 1384REPORT Z_FIND_BADI. *&- ... -
NND 搞Eclipse
2013-08-19 09:56 854NND,为了HANA, 我还得 ... -
SAP SE38 增强
2013-08-19 09:57 1463最近很多人在搞SE38增强,没事就在系统里面挂一个test ... -
SAP内存/ABAP内存/共享内存区别(深入浅出)
2013-03-06 11:30 3041转:http://www.zhsap.com/?fr ... -
ABAP 写入内存:ABAP memory中的Export和Import
2013-03-06 10:22 3549转:cnblogs(没有具体地址,抱歉哈!) 上图是SA ... -
SAP ABAP 格式化输出
2011-07-05 16:58 25871。从字段NUMBER输出到字段STRING,输出到屏幕不同位 ... -
SAP 计算时间-MTIME
2011-05-10 18:48 1450计算时间字段的值,例如Structure EMG_FILEIN ... -
Call Transaction - using
2011-03-29 08:57 2355Call transaction 的时候,我们会用到using ... -
BDC技术
2010-11-02 08:35 1374BDC技术 写的很清晰~! ... -
ABAP性能优化
2010-11-02 08:34 1658ABAP性能优化 1.使用二分法查询,提高查询内表数据速度 ... -
SAP BAPI的简单实现步骤
2010-11-02 08:32 4591ABAP中有关BAPI的介绍 1.BAPI – busines ... -
SAP:ABAP基础篇--字符串截取
2010-10-28 18:15 12166Zhuan 的哦! 1. 数字类型(numeric types ... -
查找SAP系统可操作的用户出口
2010-10-13 10:04 1166转——Jack Wu http://blog.csdn.net ... -
SMOD和CMOD-SAP 留给开发人员的接口
2010-10-13 09:58 2630转SAP BLOG--Jack Wu http://blog. ...
相关推荐
Master GuidePUBLIC SAP Portfolio and Project Management for SAP S/4HANA Document Version: 1.1 – 2017-02-22
SAP Overview and Navigation SAP 概述和导航是 SAP 系统的入门课程,旨在为用户提供 SAP 系统的整体架构和导航方法的概述。本课程将介绍 SAP 系统的结构、模块、业务流程和导航方法,为用户提供了一个完整的 SAP ...
SAP Basic Technology - SAPBW and BEx Suite
sap press doc 解压密码:abap_developer
In this introduction, I explain the meaning of the acronym SAP, the origin of SAP, and the concept of SAP implementation. We will go further to look at Enterprise Resource Plan
### SAP S/4HANA Sourcing and Procurement认证应用关联知识点 #### 一、SAP Best Practice 内容层次结构 1. **解决方案包(Solution Packages)** 解决方案包是SAP Best Practice 的顶层构建模块,包含了一系列...
### SAP Portfolio and Project Management (PPM) 配置详解 #### 概述 SAP Portfolio and Project Management(简称SAP PPM)是一款功能强大的企业级解决方案,它为企业提供了全面的项目管理和投资组合管理功能。...
SAP S4HANA Sourcing and Procurement知识点总结 SAP S4HANA Sourcing and Procurement是一个复杂的企业资源规划系统,旨在帮助企业更好地管理采购和供应链。以下是SAP S4HANA Sourcing and Procurement的关键知识...
sap sale and distribution level 2
英文书籍,排版及页面清晰度不错,对SAP SD的相关知识还是比较全面的,个人建议有一定英语基础的人并且具备SAP基础知识的人去学习。
SAP Ariba Buying and Invoicing Introduction which can help to guide yourself.
#### 转换与加载 (Transformation and Load) SAP BW 支持多种数据转换技术,包括标准转换规则、公式和脚本编程。这些工具使得用户可以根据具体需求定制数据转换逻辑。加载过程则负责将转换后的数据存储到 SAP BW ...
这是一个ABAP子程序SUBMIT调用的方法,要根据实际灵活使用。
SAP的变更和传输系统(Change and Transport System,简称CTS)是SAP环境中一个至关重要的组件,主要用于管理和传输ABAP工作台以及定制化中的开发项目。这个系统确保了在不同SAP系统和客户端之间安全、有序地转移...
ERP信息化专业资料:SAP专业学习资料SAP_MM___Functionality_and_Technical_Configuration.pdf
学习SAP Gateway和OData的相关资源包括SAP PRESS出版的书籍,如Anil Bavaraju的《SAP Fiori Implementation and Development》、Goebels, Nepraunig, Seidel的《SAPUI5: The Comprehensive Guide》、Stefan Haas和...
Configuring SAP ERP Sales and Distribution
SAP AFS( Apparel and Footwear Solution)是SAP公司针对服装和鞋类行业推出的一套全面的解决方案,旨在帮助企业高效地管理多维码物料、库存、订单和生产过程。在这个解决方案中,SAP AFS充分利用现代信息技术,为...
SAP(System, Applications, and Products in Data Processing)是全球领先的业务软件解决方案供应商之一。SAP系统被广泛应用于各种规模的企业中,用于集成企业内部的所有业务流程,并实现自动化操作。SAP管理涉及...
Implementing SAP Sales and Distribution.pdf 第二部分