Received: from pirania.dif.um.es (IDENT:root@pirania.dif.um.es [155.54.210.33]) by hub.org (8.10.1/8.10.1) with ESMTP id e95Bbo794728 for ; Thu, 5 Oct 2000 07:37:52 -0400 (EDT) Received: from dif.um.es (IDENT:gabilm@pirania.dif.um.es [127.0.0.1]) by pirania.dif.um.es (8.9.3/8.9.3) with ESMTP id NAA03604 for ; Thu, 5 Oct 2000 13:36:32 +0200 Message-ID: <39DC67BF.A28489A2@dif.um.es> Date: Thu, 05 Oct 2000 13:36:31 +0200 From: Gabriel Lopez X-Mailer: Mozilla 4.72 [es] (X11; U; Linux 2.2.14-5.0 i686) X-Accept-Language: en MIME-Version: 1.0 CC: psql Subject: Re: wrong documentation and others ..... References: <39DC5F29.E9F4023@dif.um.es> <004f01c02ebd$8f30a380$97bfedd4@pc4151> Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Archive-Number: 200010/15 Troels Jegbjaerg Moerch escribió: > Hi try this: File file = new File("myimage.gif"); > FileInputStream fis = new FileInputStream(file); > byte[] theByteArray = new byte[fis.available()]; > fis.read(theByteArray); > > PreparedStatement ps = con.prepareStatement("insert insert into > images values (?,?)"); ps.setString(1,file.getName()); > ps.setBytes(2, theByteArray); > ps.execute(); > con.commit(); > ps.close(); > fis.close(); > TJM Yes, it work fine, but each 9 times it fail: FATAL 1: my bits moved right off the end of the world! Recreate index pg_attribute_relid_attnam_index. Anybody known why? Thanks -- Gabriel López Millán Facultad de Informática -Universidad de Murcia 30001 Murcia - España (Spain) Telf: +34-968-364644 E-mail: gabilm@dif.um.es