Skip to content

Show Buckets in Hash joins #797

Description

@Krysztophe

Is your feature request related to a problem? Please describe.

In a hash join, such lines will appear. I don't see them in the graphical plan, although they may help to estimate how high work_mem×hash_mem_mutliplier must be to avoid temp files:

         Buckets: 1048576  Batches: 16  Memory Usage: 62533kB
         Buffers: shared hit=14909 read=98728, temp written=88109

(Source, JSON version )

Another example with a HashAggregate here, with a another field, Planned Partitions:

Describe the solution you'd like

  • Print somewhere the information about Buckets and Batches and Memory, and the total ( about 1 GB in the example)

Describe alternatives you've considered

Temporary files information is not always accurate enough (here only 690 MB, although the hash join wants 1 GB to run in memory)

Additional context

I have a script in a private repo, and it will probably be included in dali.bo/j6_html soon.

This information was already there in PG 9.1.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions