Попробуйте:
select a.quarter_date, a.country, a.total_shipping, b.total_dollar_value, b.total_quantity
from
(select quarter_date, country, sum(shipping_total) as total_shipping
from
(select distinct quarter_date, country, shipping_total
from transaction_detail_mv)c
group by quarter_date,country
)a
join -- Below is part of your query
(select QUARTER_DATE ,COUNTRY,sum(DOLLAR_VALUE_US) as total_dollar_value, sum(QUANTITY) as total_quantity
from transaction_detail_mv
group by QUARTER_DATE,COUNTRY)b
on a.quarter_date = b.quarter_date
and a.country = b.country
Результат теста:
DB <> Fiddle