with t1 as (
    select order_id,brand_id,order_date,return_status
    from sales_orders
    where month(order_date) = 7
)
select b.brand_id,brand_name,
round(sum(return_status)/count(return_status),2) return_rate_July_2024,
round(avg(customer_satisfaction_score),2) average_customer_satisfaction_score
from brand_info b join t1 on b.brand_id = t1.brand_id
join customer_feedback c on t1.order_id = c.order_id
group by b.brand_id
order by b.brand_id