Skip site navigation (1) Skip section navigation (2)

JDBC - error reading BLOBs

From: Nelson Ferreira Jr <nelson(at)radix(dot)com(dot)br>
To: pgsql-interfaces(at)postgresql(dot)org
Subject: JDBC - error reading BLOBs
Date: 2000-07-15 12:26:13
Message-ID: (view raw or whole thread)
Lists: pgsql-interfaces

  I got the following error when reading BLOBs from a database.
works fine when there is a few concurrent requests, but when putting the

servlet in a heavy-load situation, I got the following errors:

ERROR:  lo_tell: invalid large object descriptor (0)
ERROR:  lo_close: invalid large obj descriptor (1)
ERROR:  lo_read: invalid large obj descriptor (1)
ERROR:  lo_lseek: invalid large obj descriptor (1)

  It only happens with 10 or more concurrent requests, and about 5% of
requests fails. Here is the code:

   pstmt =con.prepareStatement(query_gif);
   ResultSet rs_gif = pstmt.executeQuery();

   if ( {
       BufferedInputStream gifDados = new
       byte[] buf =new byte[4*1024]; //4Kb buffer
       int tam;
       while ((tam,0,buf.length)) != -1){
           out.write(buf,0,tam); // Its the PrintWriter of my Servlet


    I am runnig postgreSQL 7.0.2 on a RedHat 6.2 linux



pgsql-interfaces by date

Next:From: Matt FairDate: 2000-07-15 18:09:09
Subject: JDBC Query bug
Previous:From: Peter MountDate: 2000-07-15 09:53:24
Subject: Re: How do I use connection pooling?

Privacy Policy | About PostgreSQL
Copyright © 1996-2015 The PostgreSQL Global Development Group