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

Please Help me out

Former Member
0 Likes
596

TABLE VEKP

VENUM EXIDV VHILM

4 A XYZ

5 B XYZ

TABLE VEPO

VENUM UNVEL MATNR

1 - X

2 - Y

3 - Z

4 3 -

4 2 -

5 1 -

THE OUTPUT SHOULD BE

EXIDV MATNR

A X

A Y

B Z

*This is the whole scenario can anyone please help me out with this*

Edited by: rajesh nautiyal on Dec 9, 2011 8:01 AM

Moderator message : Spec dumping not allowed, thread locked.

Edited by: Vinod Kumar on Dec 9, 2011 5:20 PM

3 REPLIES 3
Read only

madhu_vadlamani
Active Contributor
0 Likes
549

Hi Rajesh,

Nothing is clear from where you are picking the data.What are the tables you are using.What you need too display in out put.if you simple say whole scenario difficult to understand.

Regards,

Madhu.

Read only

Former Member
0 Likes
549

TABLE VEKP

VENUM EXIDV VHILM

4 A XYZ

5 B XYZ

TABLE VEPO

VENUM UNVEL MATNR

1 - X

2 - Y

3 - Z

4 3 -

4 2 -

5 1 -

THE OUTPUT SHOULD BE

EXIDV MATNR

A X

A Y

B Z

select vekpexidv vepomatnr

into corresponding fields of talbe lt_data

from vepo as vepo inner join vekp as vekp on vepovenum = vekpvenum.

Read only

surajarafath
Contributor
0 Likes
549

declare an another internal table with,

TYPES: BEGIN OF  TY_ITAB,
              EXIDV TYPE VEKP-EXIDV,
              MATNR TYPE VEPO-MATNR,
             END OF TY_ITAB.

DATA ITAB TYPE TABLE OF TY_ITAB.
DATA WA_ITABL TYPE TY_ITAB.

LOOP AT VEKP.
WA_ITBL-EXIDV = VEKP-EXIDV . 
LOOP AT VEPO WHERE VENUM = VEKP-VENUM
WA_ITBL-MATNR = VEPO-MATNR.
APPEND WA_ITBL TO WT_ITBL. "<-Append only here,
ENDLOOP.
ENDLOOP.