The problem statements for the 20 queries will be :
Simple Queries: Find the total number of imposters in the database. List all imposters who have been active in the past two weeks.
Medium Queries: Find the average number of missions completed per imposter. List the top 10 imposters with the most successful missions.
Complex Queries: Find the average time it takes for imposters to complete a mission, grouped by mission type. Identify the imposter with the highest success rate in eliminating crewmates.
What are the queries for the problem statements?
1. sql
SELECT
customers.customer_id,
customers.customer_name,
orders.order_id,
orders.order_date
FROM
WideWorldImpostersDW.customers
JOIN
WideWorldImpostersDW.orders ON customers.customer_id = orders.customer_id;