On Tue, 25 Apr 2023 at 04:20, Imseih (AWS), Sami <sims...@amazon.com> wrote:
>
> Based on the feedback, here is a v1 of the suggested doc changes.
>
> I modified Gurjeets suggestion slightly to make it clear that a specific
> query execution could have operations simultaneously using up to
> work_mem.

> -        Note that for a complex query, several sort or hash operations might 
> be
> -        running in parallel; each operation will generally be allowed
> +        Note that a complex query may include several sort and hash 
> operations,
> +        and more than one of these operations may be in progress 
> simultaneously
> +        for a given query execution; each such operation will generally be 
> allowed
>         to use as much memory as this value specifies before it starts
>         to write data into temporary files.  Also, several running
>         sessions could be doing such operations concurrently.

I'm wondering about adding "and more than one of these operations may
be in progress simultaneously".  Are you talking about concurrent
sessions running other queries which are using work_mem too?  If so,
isn't that already covered by the final sentence in the quoted text
above? if not, what is running simultaneously?

I think Tom's suggestion looks fine. I'd maybe change "sort or hash"
to "sort and hash" per the suggestion from Gurjeet above.

David


Reply via email to