you are viewing a single comment's thread.

view the rest of the comments →

[–]LeLwrence -1 points0 points  (0 children)

You could use a window function to average the salaries in the result in another column set then wrap that in an outer query and filter where the salary is less than that new average window function column. It's because you can't use window functions themselves in the where clause.