pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Oliver Jowett <oliver@opencloud.com>
To: Pucky Loucks <ploucks@h2st.com>
Cc: pgsql-jdbc@postgresql.org
Subject: Re: Java Studio Creator Fix/Hack
Date: Sat, 11 Dec 2004 13:45:35 +1300
Message-ID: <41BA432F.2020607@opencloud.com> (raw)
In-Reply-To: <27935D81-4AF8-11D9-BF6C-000D9344294E@h2st.com>
References: <27935D81-4AF8-11D9-BF6C-000D9344294E@h2st.com>

Pucky Loucks wrote:

> org.postgresql.jdbc2.AbstractJdbc2Statement.getMetaData() to the following. [...]

> connection.getQueryExecutor().execute(preparedQuery,
> preparedParameters,
> handler,
> 0,
> 0,
> QueryExecutor.QUERY_ONESHOT);
> rs = handler.getResults().getResultSet();
> }

Danger, danger. This actually *executes* the query. 
Statement.getMetaData() isn't meant to do that!

-O



view thread (4+ messages)  latest in thread

Message-ID: <41BA432F.2020607@opencloud.com>
Permalink:  ../41BA432F.2020607@opencloud.com/
Also on:    postgresql.org/message-id/41BA432F.2020607@opencloud.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: oliver@opencloud.com, ploucks@h2st.com
  Subject: Re: Java Studio Creator Fix/Hack
  In-Reply-To: <41BA432F.2020607@opencloud.com>
  References: <27935D81-4AF8-11D9-BF6C-000D9344294E@h2st.com> <41BA432F.2020607@opencloud.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