Subject Re: memory leaks?
Author Roman Rokytskyy
Hi,

I'm not sure if this can be a problem, but why do you use InterClient
specific classes to open and close connections? Usually people use
java.sql.DriverManager to open connection and connection.close() to
close the connection.

If this does not help, try our type 4 JCA-JDBC driver (JayBird), it's
available from SourceForge. If you want to keep using InterClient, you
should try InterClient 2.5 from Borland (it is shipped with InterBase
6.5, not free). Firebird team does not develop InterClient, and
version 2.01 is the last version of this software available from
Firebird project.

Best regards,
Roman Rokytskyy

--- In Firebird-Java@y..., "alesjelovsek" <software@c...> wrote:
> > Hello!
> >
> > We have experiance some problems using InterClient. IT seems like
> > connections to
> > database are not closed or at least some of them are not closed so
> computer
> > runs out
> > of memory because of that.
> > We are using Tomcat Version 4.0.4.
> > Attached see java code for creating and closing connection.
> >
> > Here are some other code snippets:
> >
> > DBConnection connection = new DBConnection();
> > Connection con = connection.getConnection();
> > String strQuery = "SELECT * FROM
> P_GetPostajalisceNaziv("+strPostajalisceID+")";
> >
> > PreparedStatement pst = con.prepareStatement(strQuery);
> > ResultSet rs = pst.executeQuery();
> > if (rs.next()) {
> > postajalisce = rs.getString("oNazivDelovni");
> > }
> >
> > rs.close();
> > pst.close();
> >
> > if (connection != null) connection.freeConnection();
> >
> > I hope someone can give us some poitners what could be wrong with
> our code
> > or some other solution.
> >
> > TIA and best regards,
> >
> > Matjaz