Re: Proposal: QUALIFY clause - Mailing list pgsql-hackers

From Vik Fearing
Subject Re: Proposal: QUALIFY clause
Date
Msg-id a042f530-90a4-46fc-8595-43053fcfc06e@postgresfriends.org
Whole thread Raw
In response to Proposal: QUALIFY clause  (Matheus Alcantara <matheusssilv97@gmail.com>)
Responses Re: Proposal: QUALIFY clause
List pgsql-hackers
On 21/07/2025 14:47, Matheus Alcantara wrote:
> Hi all,
>
> I'm sending a proof-of-concept patch to add support for the QUALIFY
> clause in Postgres. This feature allows filtering rows after window
> functions are computed, using a syntax similar to the WHERE or HAVING
> clauses.


I took a very brief look at this, and I think your grammar is wrong.  
The QUALIFY clause should go after the WINDOW clause, just like 
FROM/WHERE and GROUP BY/HAVING.


That is what I am proposing to the standards committee, and I already 
have some buy-in for that.

-- 

Vik Fearing




pgsql-hackers by date:

Previous
From: Nathan Bossart
Date:
Subject: Re: Verify predefined LWLocks tranches have entries in wait_event_names.txt
Next
From: Vik Fearing
Date:
Subject: Re: Proposal: QUALIFY clause