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

Get data using one SELECT.

Former Member
0 Likes
446

Friends,

I have a ZITAB1 contains following fields.

PKNUM - Key field of Ztable and other table ZITAB2 (used in FOR ALL ENTRIES) also

MANDT PKNUM SUB_PKNUM PKQTY MEINS

100 14201 14202 0.00

100 14202 10.00 EA

100 14202 12.00 EA

100 14202 15.00 EA

I want to select all these quantites "FOR ALL ENTRIES IN ZITAB2".

Can I do it in one SELECT statement only?

Regards,

RH

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
422

Hi,

Please Search in SCN Before Posting. Please see the SCN Rules Before Posting.

With Regards,

Sumodh.P

2 REPLIES 2
Read only

Former Member
0 Likes
423

Hi,

Please Search in SCN Before Posting. Please see the SCN Rules Before Posting.

With Regards,

Sumodh.P

Read only

Former Member
0 Likes
422

Hi ,

Try this code...

select PKNUM SUB_PKNUM PKQTY MEINS from z1tab1

into table it_tab

for all entries in it_tab2

where pknum = it_tab2-pknum

where it_tab have strucuture like Z1TAB1 and it_tab2 have structure like Z1TAB2.

before performing select query, move the data present in Z1TAB2 to internal table it_tab1.

Hope this will help you.

Regards,

Lokeswari.