On Tue, Jan 21, 2025 at 1:21 AM Tatsuo Ishii <is...@postgresql.org> wrote: > It needs lots of work including modifying CREATE FUNCTION > command. Instead you could add an API to WinObject access functions to > export ignore_nulls value. Then let each window function check it. If > the window function should not take IGNORE/RESPECT NULLS option, throw > an error.
Attached version moves the setting of IGNORE_NULLS to the window function itself, with the functions that don't allow it erroring out. This is done with a new api: WinCheckAndInitializeNullTreatment. Custom functions that don't call this will simply not have the IGNORE_NULLS option set as this api initializes the option and the array. As per the previous discussion, it should have correct formatting and handle the Exclusion clauses correctly.
0004-ignore-nulls.patch
Description: Binary data