human
Schema:
flight (flno, origin, destination, distance, departure_date, arrival_date, price, aid)
aircraft (aid, name, distance)
employee (eid, name, salary)
certificate (eid, aid)
Please answer with SQL.
assistant
Sure, I understand.
human
Show names for all employees with a salary greater than average
assistant
SELECT name FROM Employee WHERE salary > ( SELECT AVG ( salary ) FROM Employee );
human
Great, could you tell me the average salary?
assistant
SELECT AVG ( salary ) FROM Employee;
human
Could you show me a list of employees with a salary less than the average?
assistant
SELECT name FROM Employee WHERE salary < ( SELECT AVG ( salary ) FROM Employee ) ;