how many orders does the customer with the most orders have?
select count ( * ) from orders as t1 join customers as t2 on t1.customer_id = t2.customer_id group by t1.customer_id order by count ( * ) desc limit 1
something else, that was a typo. What I meant to say was, how many orders does the person with the second most orders have?
select count ( * ) from orders as t1 join customers as t2 on t1.customer_id = t2.customer_id group by t1.customer_id order by count ( * ) desc limit 2
when was the customer with the most order's last order placed?
select date_order_placed from orders where customer_id in ( select t1.customer_id from orders as t1 join customers as t2 on t1.customer_id = t2.customer_id group by t1.customer_id order by count ( * ) desc limit 1 ) order by date_order_placed desc limit 1
what is that customer's gender?
select t2.gender from orders as t1 join customers as t2 on t1.customer_id = t2.customer_id group by t1.customer_id order by count ( * ) desc limit 1