Salam semuanya,
TABLE_1
DATA_UID AMOUNT
--------------- ------------
1 4
1 3
2 20
TABLE_2
DATA_UID AMOUNT
--------------- -------------
1 7
2 24
Klo queri spt ini,
select data_uid, sum(amount)
from table_1 a
group by data_uid
having sum(amount) <> (select sum(amount)
from table_2 b
where b.data_uid = a.data_uid )
hasilnya :
DATA_UID AMOUNT
--------------- -------------
2 20
klo Amount yg di inginkan adalah selisih antara TABLE_1 dan TABLE_2,
kira* querinya spt apa ya ? (amountnya = 4 bukan 20)
slm/Aly
Send instant messages to your online friends http://uk.messenger.yahoo.com
[Non-text portions of this message have been removed]