Attempt to clean up ExecSql() in JDBC - Mailing list pgsql-jdbc

From Anders Bengtsson
Subject Attempt to clean up ExecSql() in JDBC
Date
Msg-id Pine.LNX.4.33.0108262036270.2048-300000@sensenet.localdomain
Whole thread Raw
Responses Re: Attempt to clean up ExecSql() in JDBC
Re: Attempt to clean up ExecSql() in JDBC
List pgsql-jdbc
Hi,

Attached is my attempt to clean up the horrors of the ExecSQL() method in
the JDBC driver.

I've done this by extracting it into a new method object called
QueryExecutor (should go into org/postgresql/core/) and then taking it
apart into different methods in that class.

A short summary:

* Extracted ExecSQL() from Connection into a method object called
  QueryExecutor.

* Moved ReceiveFields() from Connection to QueryExecutor.

* Extracted parts of the original ExecSQL() method body into smaller
  methods on QueryExecutor.

* Bug fix: The instance variable "pid" in Connection was used in two
  places with different meaning. Both were probably in dead code, but it's
  fixed anyway.

/Anders


PS.: If anyone has any idea what the variable names "fqp" and "hfr" stand
for, please tell me! :)

_____________________________________________________________________
A n d e r s  B e n g t s s o n                   ndrsbngtssn@yahoo.se
Stockholm, Sweden

Attachment

pgsql-jdbc by date:

Previous
From: Rene Pijlman
Date:
Subject: JDBC Statement.executeBatch patch
Next
From: Rene Pijlman
Date:
Subject: Status of JDBC test suite?