select
    brand_id,
    brand_name,
    round(sum(return_status) / count(return_status), 2) as return_rate_July_2024,
    round(avg(customer_satisfaction_score), 2) as average_customer_satisfaction_score
from
    sales_orders
    join customer_feedback using (order_id)
    join brand_info using (brand_id)    
where
    date_format(order_date, '%Y-%m') = '2024-07'
group by
    brand_id,
    brand_name
order by
    brand_id asc;