Application Development 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: 

select and append

Former Member
0 Kudos

hello friends,

i tried the below code,

it was giving sytax error appending,

can some one correct it.

loop at i_marc.

select aennr aetyp objkt revlv aedat ccsto from aeoi

into APPENDING CORRESPONDING FIELDS OF TABLE lt_aeoi

where matnr in i_marc.

endloop.

thanks.

1 ACCEPTED SOLUTION

Former Member
0 Kudos

remove into before appending ..

loop at i_marc.

select aennr aetyp objkt revlv aedat ccsto from aeoi

APPENDING CORRESPONDING FIELDS OF TABLE lt_aeoi

where matnr in i_marc.

endloop.

thanks.

5 REPLIES 5

Former Member
0 Kudos

remove into before appending ..

loop at i_marc.

select aennr aetyp objkt revlv aedat ccsto from aeoi

APPENDING CORRESPONDING FIELDS OF TABLE lt_aeoi

where matnr in i_marc.

endloop.

thanks.

b_deterd2
Active Contributor
0 Kudos

delete APPENDING in your code

Former Member
0 Kudos

Hi Sanjana,

you have to type like

loop at i_marc.

select aennr aetyp objkt revlv aedat ccsto from aeoi

into CORRESPONDING FIELDS OF TABLE lt_aeoi

where matnr in i_marc.

endloop.

you must not use appending.its not the syntax.

rewards points if helpful.

Former Member
0 Kudos

Hi Sanjana,

loop at i_marc.

select aennr aetyp objkt revlv aedat ccsto from aeoi
APPENDING CORRESPONDING FIELDS OF TABLE lt_aeoi
where matnr in i_marc.
endloop.

Regards,

Sunil

Former Member
0 Kudos

Hi,

Take out 'into' from the select statement.


loop at i_marc.

select aennr aetyp objkt revlv aedat ccsto from aeoi 
APPENDING CORRESPONDING FIELDS OF TABLE lt_aeoi 
where matnr in i_marc.

endloop.

Have u used delete adjacent duplicates for i_marc internal table before looping, otherwise you have duplicate entries.

Thanks,

Sriram Ponna.