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

Matchcode replaced with View

Former Member
0 Likes
616

Hi All,

We have created Views instead of Macthcode ID. And we have fetched data from view instead of match code and the performance of the program is very poor now.

Details of Matchcode:

Primary table      EKKO

Secondary tables   EKPO        EKET

Selection condition for Matchcode ID:

Table       MC field    Data elem.  

EKKO        MANDT       MANDT       

EKPO        EMATN       EMATNR      

Details of View:

Tables: EKKO; EKPO; EKET

Join Condition relationships on giving the above tables is:

EKKOMANDT=EKPOMANDT
EKPOMANDT=EKETMANDT
EKKOMANDT=EKETMANDT
EKKOEBELN=EKPOEBELN
EKPOEBELN=EKETEBELN
EKKOEBELN=EKETEBELN
EKPOEBELP=EKETEBELP

I am not able to include MATNR in the Join conditions as only EKPO table is having MATNR.

In most of the programs MATNR field is used in the where clause while fetching the data from match code ID/view. Please suggest how can I improve the performance. 

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
550

hello,

you have complicated your join query. please try this join condition

EKKO EBELN = EKPO EBELN

EKKO EBELN = EKET EBELN

EKPO EBELP = EKET EBELP

or else

if you know how to get data ahead of time from EKKO. Get that and then query EKPO and EKET.

best regards,

swanand

3 REPLIES 3
Read only

Former Member
0 Likes
551

hello,

you have complicated your join query. please try this join condition

EKKO EBELN = EKPO EBELN

EKKO EBELN = EKET EBELN

EKPO EBELP = EKET EBELP

or else

if you know how to get data ahead of time from EKKO. Get that and then query EKPO and EKET.

best regards,

swanand

Read only

0 Likes
550

Hi Swanand,

The sequence you have mentioned is atleast saving program from run time error, but still we have performance issue.

I did not get your point: if you know how to get data ahead of time from EKKO. Get that and then query EKPO and EKET.

Thanks,

Vachana

Read only

0 Likes
550

I meant get the required EBELN from EKKO first and then get the required data from EKPO and EKET. This way you might reduce the performance issue a little more. Join on two table (EKPO and EKET) will be a little better that join on EKKO-EKPO-EKET.