var sidebar_align = 'right';
var content_container_margin = parseInt('290px');
var sidebar_width = parseInt('270px');
Unanswered: inner join problem
I got 2 tables.
Table1 got columns ID and amt
Table2 got column ID
how to I create a join that I only get the sum of the amt in table1 for granted that the IDs in Table1 is = to the IDs in Table2.
results I want to get is sum(amt)=40
*because (S123455)10.00+(Q123454)30.00 = 40.00
*the sum do not include ID W123666 because its ID is not in Table 2.
I hope someone there will be able to help me. I am using oracle 8i which do not have the function "inner join" and that is why I am stuck.
Before ANSI came up with "INNER JOIN" we all used to get by with "="
from table1, table2
where table1.id = table2.id;
from tab1 t1
where t1.id in (select t2.id from tab2 t2);
should also work.
Last edited by Littlefoot; 08-27-04 at 07:14.