Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitd581348

Browse files
committed
Adjust documentation wording of window function ORDER BY to not mention
avg() because it was inaccurate.
1 parent8c0f1e2 commitd581348

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

‎doc/src/sgml/advanced.sgml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -383,10 +383,10 @@ SELECT depname, empno, salary, avg(salary) OVER (PARTITION BY depname) FROM emps
383383
</para>
384384

385385
<para>
386-
Although <function>avg</> will produce thesame result no matter
387-
what order it processes the partition's rows in, this is not true of all
388-
windowfunctions. When needed, you can control that order using
389-
<literal>ORDER BY</> within <literal>OVER</>. Here is an example:
386+
You can also control theorder in which rows are processed by
387+
window functions using <literal>ORDER BY</> within <literal>OVER</>.
388+
(Thewindow<literal>ORDER BY</> does not even have to match the
389+
order in which the rows are output.) Here is an example:
390390

391391
<programlisting>
392392
SELECT depname, empno, salary, rank() OVER (PARTITION BY depname ORDER BY salary DESC) FROM empsalary;

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp