From: | Huan Ruan <huan(dot)ruan(dot)it(at)gmail(dot)com> |
---|---|
To: | Kevin Grittner <kgrittn(at)mail(dot)com> |
Cc: | pgsql-performance(at)postgresql(dot)org |
Subject: | Re: hash join vs nested loop join |
Date: | 2012-12-20 01:02:17 |
Message-ID: | CAD1stZuf2Xw1RmDaZkNVZeq6MUcyPjYP8HVhd+6rSomX__ij1g@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-performance |
Frankly, at 12 microseconds per matched pair of rows, I think
> you're doing OK.
>
> This plan is the good one, I want the indexscan nested loop join and this
is only achieved after making all these costing factors change. Before
that, it was hash join and was very slow.
However, I'm worried about the config changes being too 'extreme', i.e.
both sequential I/O and random I/O have the same cost and being only 0.1.
So, I was more wondering why I have to make such dramatic changes to
convince the optimiser to use NL join instead of hash join. And also, I'm
not sure what impact will these changes have on other queries yet. e.g.
will a query that's fine with hash join now choose NL join and runs slower?
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2012-12-20 03:06:30 | Re: Why does the query planner use two full indexes, when a dedicated partial index exists? |
Previous Message | Richard Neill | 2012-12-20 00:22:49 | Re: Why does the query planner use two full indexes, when a dedicated partial index exists? |