|
|
马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。如果您注册时有任何问题请联系客服QQ: 83569622 。
您需要 登录 才可以下载或查看,没有帐号?注册
x
*&---------------------------------------------------------------------*
*& Report ZT00BB50 *
*& *
*&---------------------------------------------------------------------*
*& *
*& *
*&---------------------------------------------------------------------*
自己做的BOM查询
*&---------------------------------------------------------------------*
*& Report ZT00BB51 *
*& *
*&---------------------------------------------------------------------*
*& *
*& *
*&---------------------------------------------------------------------*
REPORT ZT00BB51 .
tables:mara,
mast,
stpo,
makt.
data: t_stb like stpox occurs 200 with header line.
data: t_date like sy-datum.
TYPE-POOLS: SLIS.
DATA:I_FIELDCAT TYPE SLIS_FIELDCAT_ALV,
I_FIELDCAT_ALV TYPE SLIS_FIELDCAT_ALV OCCURS 10,
LAYOUT TYPE SLIS_LAYOUT_ALV.
DATA:GS_LAYOUT TYPE SLIS_LAYOUT_ALV .
data: begin of itab occurs 0 ,
matnr like mara-matnr," material nomber
mtart like mara-mtart,"material type
idnrk like stpo-idnrk,"bom component 物料号
stlnr like stpo-stlnr,"bom number
WERKS like mast-WERKS," material nomber
stlan like mast-stlan,"bom useage
sortf like stpo-sortf,"Sort string
menge like stpo-menge,"Quantity
stlkn like stpo-stlkn,"item node
vgknt like stpo-vgknt,"previews node
datuv like stpo-datuv,
aennr like stpo-aennr,
maktx like makt-maktx,"material discrip
end of itab.
data: begin of itab1 occurs 0,
sortf like stpo-sortf,"Sort string
menge like stpo-menge,"Quantity
stlkn like stpo-stlkn,"item node
vgknt like stpo-vgknt,"previews node
datuv like stpo-datuv,
aennr like stpo-aennr,
end of itab1.
data: begin of itab2 occurs 0,
maktx like makt-maktx,"material discrip
end of itab2.
data: begin of itab3 occurs 0,
matnr like mara-matnr," material nomber
mtart like mara-mtart,"material type
end of itab3.
data: begin of itab4 occurs 0,
WERKS like mast-WERKS," material nomber
stlan like mast-stlan,"bom useage
end of itab4.
selection-screen begin of block block1 with frame
title text-001.
SELECT-OPTIONS: S_WLH FOR mast-matnr,
s_werks FOR mast-werks,
s_STLNR FOR mast-STLNR.
*SELECT-OPTIONS:
* parameters: s_matnr like mast-matnr obligatory ,
* s_werks like mast-werks obligatory ,
* s_stlan like mast-stlan default '2',
* s_stlal like mast-stlal default '01',
* s_date like sy-datum default sy-datum.
selection-screen end of block block1.
*PARAMETERS: R1 AS CHECKBOX .
PERFORM getdata.
PERFORM LAYOUT.
PERFORM LAYOUT_BUILD.
PERFORM OUTPUT.
form getdata.
select * from stpo
into corresponding fields of table itab1
where STLNR in s_STLNR.
select * from mara
into corresponding fields of table itab3
where matnr in S_WLH.
select * from mast
分层显示bom和自己做的BOM查询.txt
(15.21 KB, 下载次数: 5)
|
|