इसे आजमाएं:
Select code, sum(qtd)
from (
select code, qtd from sales
union all
select code, qtd from items) as innerTable
group by code
इसे आजमाएं:
Select code, sum(qtd)
from (
select code, qtd from sales
union all
select code, qtd from items) as innerTable
group by code