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: 

inner join

Former Member
0 Kudos

Hi,

While making inner join b/w 2 tables should we match all the common fileds in both the tables even if they r not key fields in the tables?

Regards,

Hema

5 REPLIES 5

JozsefSzikszai
Active Contributor
0 Kudos

hi Hema,

it is enough if you match the key fields at least of one table. For example between MARA (material and MAKT you have to match only MATNR.

You can give your own examples here, than I can help more.

hope this helps

ec

Former Member
0 Kudos

Hi,

No it is not necessary to match all the common fields, You match the fields according to your requirement. more fields you match more data will get filtered.

Former Member
0 Kudos

Hi, You can do the inner join b/w two tables with using a single field also.

like ,

<b> select select a~vbeln

a~bstnk

a~kunnr

b~posnr

b~matnr

b~netwr

into table i_basic

from vbak as a Inner join vbap as b

on avbeln eq bvbeln.</b>

Former Member
0 Kudos

If there is not direct relation between two tables, search for a relation through a 3rd table and join all three..

    • reward if solved**

Former Member
0 Kudos

Hi

Its not necessary that u have to link all the common fields in the table.Just need one joining condition.In joins we can join more than 2 tables.

Regards

Shibin