Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
Postgres FD Implementation
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Abuhujair Javed
Postgres FD Implementation
Commits
d5813488
Commit
d5813488
authored
Feb 20, 2011
by
Bruce Momjian
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Adjust documentation wording of window function ORDER BY to not mention
avg() because it was inaccurate.
parent
8c0f1e27
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
doc/src/sgml/advanced.sgml
doc/src/sgml/advanced.sgml
+4
-4
No files found.
doc/src/sgml/advanced.sgml
View file @
d5813488
...
...
@@ -383,10 +383,10 @@ SELECT depname, empno, salary, avg(salary) OVER (PARTITION BY depname) FROM emps
</para>
<para>
Although <function>avg</> will produce the same result no matter
w
hat order it processes the partition's rows in, this is not true of all
window functions. When needed, you can control that order using
<literal>ORDER BY</> within <literal>OVER</>.
Here is an example:
You can also control the order in which rows are processed by
w
indow functions using <literal>ORDER BY</> within <literal>OVER</>.
(The window <literal>ORDER BY</> does not even have to match the
order in which the rows are output.)
Here is an example:
<programlisting>
SELECT depname, empno, salary, rank() OVER (PARTITION BY depname ORDER BY salary DESC) FROM empsalary;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment