Final answer:
To find the employee who sold the most Binder Prime products between specific dates, use a SQL query that joins the employees, sales, and products tables, filters the results by brand and date range, calculates the total units sold by each employee, groups the results, and sorts them.
Step-by-step explanation:
To display the employee who sold the most Binder Prime brand products between November 1, 2017, and December 5, 2017, you can use the following SQL query:
SELECT employee_number, first_name, last_name, email, SUM(units_sold) as total_units_sold
FROM employees
JOIN sales ON employees.employee_number = sales.employee_number
JOIN products ON sales.product_id = products.product_id
WHERE brand = 'Binder Prime' AND sale_date BETWEEN '2017-11-01' AND '2017-12-05'
GROUP BY employee_number, first_name, last_name, email
ORDER BY total_units_sold DESC, last_name ASC
LIMIT 1;
This query joins the employees, sales, and products tables and filters the results based on the brand 'Binder Prime' and the specified date range. It calculates the total units sold by each employee, groups the results by employee, and then sorts the output in descending order by total units sold and ascending order by last name. Finally, it limits the output to the top employee.