examples for windows functions
Hello,
I'd like to propose to add some examples to the following page
https://www.postgresql.org/docs/16/functions-window.html
The syntax of window functions is fully covered by the page
https://www.postgresql.org/docs/16/sql-expressions.html#SYNTAX-WINDOW-FUNCTIONS
but I think it would be helpful to put some examples in
https://www.postgresql.org/docs/16/functions-window.html
Some example showing the use of preceding would be useful, like the
following
over (partition by col1 order by col2
rows between 10 preceding and 1 preceding
)
what do you think?
Thank you,
best regards
Giampaolo Capelli <giampow@gmail.com> writes:
I'd like to propose to add some examples to the following page
https://www.postgresql.org/docs/16/functions-window.html
The syntax of window functions is fully covered by the page
https://www.postgresql.org/docs/16/sql-expressions.html#SYNTAX-WINDOW-FUNCTIONS
but I think it would be helpful to put some examples in
https://www.postgresql.org/docs/16/functions-window.html
That page starts out with a link to section 3.5 which is
full of examples. Seems a bit repetitive to put more here.
regards, tom lane
Ok, but in section 3.5 I don't see examples on the "preceeding" clause.
What about enriching the section 3.5 then?
<tgl@sss.pgh.pa.us>:
Show quoted text
Giampaolo Capelli <giampow@gmail.com> writes:
I'd like to propose to add some examples to the following page
https://www.postgresql.org/docs/16/functions-window.htmlThe syntax of window functions is fully covered by the page
https://www.postgresql.org/docs/16/sql-expressions.html#SYNTAX-WINDOW-FUNCTIONS
but I think it would be helpful to put some examples in
https://www.postgresql.org/docs/16/functions-window.htmlThat page starts out with a link to section 3.5 which is
full of examples. Seems a bit repetitive to put more here.regards, tom lane