Task: Text to Code
Input (English): Step 1: find the average SALARY in employees table.
Step 2: For each row in jobs table, find the corresponding rows in employees table.
Step 3: find EMPLOYEE_ID in the results of step 2 whose MAX_SALARY greater than the results of step 1
Output (English): SELECT T2.EMPLOYEE_ID FROM jobs AS T1 JOIN employees AS T2 ON T1.JOB_ID = T2.JOB_ID WHERE T1.MAX_SALARY > ( SELECT Avg ( T2.SALARY ) FROM employees AS T2 )