Re: Query performance with small data base

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: pginfo <pginfo(at)t1(dot)unisoftbg(dot)com>
Cc: pgsql-general <pgsql-general(at)postgresql(dot)org>
Subject: Re: Query performance with small data base
Date: 2002-10-18 01:51:09
Message-ID: 13507.1034905869@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

pginfo <pginfo(at)t1(dot)unisoftbg(dot)com> writes:
> explain analyze select
> S.IDS_NUM,S.OP,S.KOL,S.OTN_MED,S.CENA,S.DDS,S.KURS,S.TOT,S.DTO,S.PTO,S.DTON,MED.MNAME
> AS MEDNAME,N.MNAME AS NOMENNAME,N.NUM AS NNUM,S.PART,S.IZV from A_DOC
> D left outer join A_KLIENTI KL ON(D.IDS_KO=KL.IDS) , A_SKLAD S left
> outer join A_NOMEN N ON(S.IDS_NUM=N.IDS) left outer join A_MED MED ON
> (N.OSN_MED=MED.IDS ) WHERE S.FID=0 AND S.IDS_DOC=D.IDS AND
> D.DATE_OP >= 8353 AND D.DATE_OP <= 9983 ORDER BY S.IDS_NUM,S.PART,S.OP

Hmm, seems like most of the cycles are going into hash joins. What
explain result do you get if you do "set enable_hashjoin to off"?

regards, tom lane

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Andrew Bartley 2002-10-18 03:05:10 Re: pg_attribute always grow...
Previous Message Stephan Szabo 2002-10-18 01:43:50 Re: imploding/using arrays for IN (...)