Skip to Content
0
Former Member
Feb 08, 2005 at 10:39 AM

Internal table insiden BSP.

28 Views

Hi,

Pretty new to BSP but have been working with ABAP for 2 months now... 😊

Types definition:

types: begin of t_MasterDataStruct,

X_EKKO_EBELN type EKKO-EBELN,

X_EKKO_LIFNR type EKKO-EBELN,

X_EKKO_BEDAT type EKKO-BEDAT, " Huvudnivå, När po skapades..ikke intressant?

X_LFA1_NAME1 type LFA1-NAME1,

X_EKPO_EBELP type EKPO-EBELP, " Linje nr.

X_EKPO_MATNR type EKPO-MATNR,

X_EKPO_MENGE type EKPO-MENGE, " Totalt per linje

X_EKES_MENGE type EKES-MENGE, " Antal bekräftade per linje.

X_EKES_EINDT type EKES-EINDT, " Datum för bekräftat.

X_EKET_MENGE type EKET-MENGE, " Antal obekräftat per linje

X_EKET_EINDT type EKET-EINDT, " Datum för obekräftat

end of t_MasterDataStruct.

Eventhandler: oninitialization:

data: i_MasterDataTab type table of t_MasterDataStruct.

select

X_EKKO~EBELN

X_EKKO~LIFNR

X_EKKO~BEDAT " Huvudnivå, När po skapades..ikke intressant?

X_LFA1~NAME1

X_EKPO~EBELP " Linje nr.

X_EKPO~MATNR

X_EKPO~MENGE " Totalt per linje

X_EKES~MENGE " Antal bekräftade per linje.

X_EKES~EINDT " Datum för bekräftat.

X_EKET~MENGE " Antal obekräftat per linje

X_EKET~EINDT " Datum för obekräftat

from EKKO as X_EKKO

inner join LFA1 as X_LFA1 on X_LFA1LIFNR = X_EKKOLIFNR

inner join EKPO as X_EKPO on X_EKPOEBELN = X_EKKOEBELN

left outer join EKES as X_EKES on X_EKESEBELN = X_EKPOEBELN AND X_EKESEBELP = X_EKPOEBELP

left outer join EKET as X_EKET on X_EKETEBELN = X_EKPOEBELN AND X_EKETEBELP = X_EKPOEBELP

into corresponding fields of i_MasterDataTab

where

X_EKKO~EBELN = '5600000029'.

In my layout i want to make a loop and write everything (i_MasterDataTab) to screen.

Error: You cannot use an internal table as a work area.

How can I fix this problem ?

//Martin