es     |     1 |   5000 | 4866.6666666666666667
 sales     |     4 |   4800 | 4866.6666666666666667
(10 rows)
</pre><p>

    The first three output columns come directly from the table
    <code class="structname">empsalary</code>, and there is one output row for each row in the
    table.  The fourth column represents an average taken across all the table
    rows that have the same <code class="structfield">depname</code> value as the current row.
    (This actually is the same function as the non-window 