05-28-2006 2:32 AM
HI Friends,
I have 4 internal tables,
it_vbak - data from VBAK
it_vbap - data from VBAP
it_vbpa _ data from VBPA
the data i got into the above tables is using vbeln as my select options.
I need to move all the data from the above internal table to one internal table it_vbak_vbap_vbpa.
with a unique key,
in the above case the unique key i am using is VBELN.
Any help on this will be appericiated.
Bye,
Shejal.
05-28-2006 2:42 AM
Hi,
Use a join and select directly into one internal table if possible.
Else you will have to loop at each table individually using a nested loop and move the data to the common internal table.
Cheers
VJ
05-28-2006 2:42 AM
Hi,
Use a join and select directly into one internal table if possible.
Else you will have to loop at each table individually using a nested loop and move the data to the common internal table.
Cheers
VJ
05-28-2006 2:49 AM
Hi Rao,
Do u mean do an inner join. If so how should i apporach for it. first do an inner join only for 2 tables in a 3rd table and then perform another inner join between the 3rd table and the other table.
let me know,
bye,
Shejal.
05-28-2006 2:54 AM
Hi ,
You can do a inner join on 3 tables directly using the relvant key fields if available.
Generally inner joins is preferred on 2 tables but if you have all the key fields then you can do an inner join on 3 tables or even more.
SOme times its good to use inner joins and some times its not good to use a inner join. It all depends on from which table you are selecting data , how many tables are involved and how many key fields are available.
In ur case guess u can use a inner join on all 3 tables as the sales tables are not so huge compared to finance tables.
Cheers
VJ
05-28-2006 3:01 AM