What is the name of the customer who has the most orders?
select t1.customer_name from customers as t1 join orders as t2 on t1.customer_id = t2.customer_id group by t1.customer_id order by count(*) desc limit 1
What's his or her id?
select t1.customer_id from customers as t1 join orders as t2 on t1.customer_id = t2.customer_id group by t1.customer_id order by count(*) desc limit 1