Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Internal table

Former Member
0 Likes
449

Hi experts,

I wanted to put complete fields of 2 table(mara and makt) into a single internal table.

when i tried with

ypes: begin of itab.

INCLUDE STRUCTURE MARA.

include structure makt.

types: END OF ITAB.

it is showing the error as Mandt already exits. Can you please give me some suggestions. It is urgent.

Regards,

John Mani

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
422

**Define Internal table like e.g. given below

REPORT ZTRIP_TEST .

tables : MARA,MAKT.

data:

begin of ITAB occurs 0,

mara like mara,

makt like makt,

end of ITAB.

reward points if found useful

4 REPLIES 4
Read only

Former Member
0 Likes
422

You can specify the MARA sturcture and will have to define each field off MAKT. There is not that many.

Read only

Former Member
0 Likes
422

types: begin of itab.

INCLUDE STRUCTURE MARA.

f1 type makt-filed1

......

...fn type mark-fieldn

types: END OF ITAB.

Read only

Former Member
0 Likes
423

**Define Internal table like e.g. given below

REPORT ZTRIP_TEST .

tables : MARA,MAKT.

data:

begin of ITAB occurs 0,

mara like mara,

makt like makt,

end of ITAB.

reward points if found useful

Read only

Former Member
0 Likes
422

this is because mandt field is present in both the table(also matnr) and you are trying to insert those fields twice in your itab so you have to do like this...

TABLES : MARA,makt.

data : begin of itab occurs 0.

include structure mara.

data : SPRAS like makt-spras,

MAKTX like makt-maktx,

MAKTG like makt-maktg,

end of itab.

regards

shiba dutta