pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Flipper <flipper@gammadue.com>
To: pgsql-jdbc@postgresql.org
Subject: Re: prepared statement: are they pre-compiled?
Date: Thu, 5 Jul 2007 12:08:59 +0200
Message-ID: <200707051208.59443.flipper@gammadue.com> (raw)
In-Reply-To: <468CB19F.6080108@enterprisedb.com>
References: <200707051023.25650.flipper@gammadue.com>
	<468CB19F.6080108@enterprisedb.com>

On Thursday 5 July 2007 Heikki Linnakangas's cat, walking on the keyboard, 
wrote:
> It depends on the prepareThreshold parameter. The default is 5, which
> means that the query is parsed and planned separately for each call to
> executeQuery, until the 5th call. After that, a generic plan is
> generated and used thereafter.

Thanks for you explaination!
Where is this default parameter set? I cannot find it.
By the way, I cannot see the real difference in the code, and in fact the 
QueryExecutor goes into the sendParse with oneShot = false (since the flag 
has not been set). The sendParse creates a statement name and then sends the 
parse message. So the doubt is: the parse message is always sent and the 
server ignores it when a statement name is provided? Or is something in the 
Java code that I'm not getting?

Thanks



view thread (5+ messages)  latest in thread

Message-ID: <200707051208.59443.flipper@gammadue.com>
Permalink:  ../200707051208.59443.flipper@gammadue.com/
Also on:    postgresql.org/message-id/200707051208.59443.flipper@gammadue.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-jdbc@postgresql.org
  Cc: flipper@gammadue.com
  Subject: Re: prepared statement: are they pre-compiled?
  In-Reply-To: <200707051208.59443.flipper@gammadue.com>
  References: <200707051023.25650.flipper@gammadue.com> <468CB19F.6080108@enterprisedb.com> <200707051208.59443.flipper@gammadue.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox