w3resource_MySQL练习题:Basic_select_statement 1. Write a query to display the names (first_name, last_name) using alias name "First Name", "Last Name" Sample table: employees -- 要点:as设置别名,as可省略 select first_name as "First Name",…
w3resource_MySQL练习题:Joins 1. Write a query to find the addresses (location_id, street_address, city, state_province, country_name) of all the departments Hint : Use NATURAL JOIN. Sample table: locations Sample table: countries -- 1. 自然连接,MySQL自己判断多表的…
w3resource_MySQL练习题:Subquery 1. Write a query to find the name (first_name, last_name) and the salary of the employees who have a higher salary than the employee whose last_name='Bull' Sample table: employees -- 要点:where里select select first_name, las…
w3resource_MySQL练习题:Aggregate_functions   1. Write a query to list the number of jobs available in the employees table Sample table: employees -- 要点:count() + distinct select count(distinct job_id) from employees 2. Write a query to get the total sal…