JDBC and BLOB in Postgres

Поиск
Список
Период
Сортировка
От Didier Boudigue
Тема JDBC and BLOB in Postgres
Дата
Msg-id 39DDC53B.DC22F0BE@nextenso.com
обсуждение исходный текст
Ответы Re: JDBC and BLOB in Postgres  (Peter Mount <peter@retep.org.uk>)
Re: JDBC and BLOB in Postgres  (Peter Mount <peter@retep.org.uk>)
Список pgsql-interfaces
Hi,

I'm trying  Blob with JDBC Driver jdbc7.0-1.2  on postgresql 7.0.2
(Mandrake 7.1) follwing the example given in paragraph "Using Large
Objects" Chapter 58. JDBC Interface.

the getBinaryStream seems ok provided the blob is in the database, 
while the setBinaryStream method call returns : 
Error : InputStream as parameter not supported

Did I miss something ?

Thanks in advance.

The Code I'm using: 

File file = new File("Blob.class");
FileInputStream fis = new FileInputStream(file);            
cx.setAutoCommit(false);
ps = cx.prepareStatement("insert into mytable (myid, myblob) values (1,
?)");
ps.setBinaryStream(1, fis, (int) file.length());
ps.executeUpdate();
ps.close();
fis.close();
cx.commit();






В списке pgsql-interfaces по дате отправления:

Предыдущее
От: "Erny"
Дата:
Сообщение: Driver or Postgres doesn't report refer. integr. errors
Следующее
От: Didier Boudigue
Дата:
Сообщение: JDBC and BLOB in Postgres