select
b.brand_id,
b.brand_name,
round(sum(s.return_status)/count(s.order_id),2) as return_rate_July_2024,
round(avg(f.customer_satisfaction_score),2) as average_customer_satisfaction_score
from brand_info b
left join sales_orders s on b.brand_id=s.brand_id
left join customer_feedback f on s.order_id=f.order_id
where s.order_date between '2024-07-01' and '2024-07-31'
group by
b.brand_id,b.brand_name
order by
b.brand_id



京公网安备 11010502036488号