Re: Jdbc/postgres performance

From: "Merlin Moncure" <mmoncure(at)gmail(dot)com>
To: Rohit_Behl <Rohit_Behl(at)infosys(dot)com>
Cc: pgsql-performance(at)postgresql(dot)org
Subject: Re: Jdbc/postgres performance
Date: 2006-10-17 20:28:49
Message-ID: b42b73150610171328r508ab94dmd70dac6ed78474aa@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

On 10/17/06, Rohit_Behl <Rohit_Behl(at)infosys(dot)com> wrote:
> Select events.event_id, ctrl.real_name, events.tsds, events.value, events.lds, events.correction, ctrl.type, ctrl.freq from table events, iso_midw_control ctrl where events.obj_id = ctrl.obj_id and events.event_id > ?::bigint order by events.event_id limit ?

unfortunately parameterized limit statements cause problems due to the
fact the planner has a hard coded 'guess' of 10% of rows returned when
the plan is generated. I mention this everyime query hints proposal
comes up :-).

best you can do is to try turning off seqscan and possibly bitmap scan
when the plan is generated.

merlin

In response to

Responses

Browse pgsql-performance by date

  From Date Subject
Next Message Bucky Jordan 2006-10-18 00:47:03 Re: Jdbc/postgres performance
Previous Message Rohit_Behl 2006-10-17 19:45:40 Jdbc/postgres performance