From: | Paul Thomas <paul(at)tmsl(dot)demon(dot)co(dot)uk> |
---|---|
To: | Akash Shah <akash(dot)s(at)ap(dot)sony(dot)com> |
Cc: | "pgsql-jdbc (at) postgresql (dot) org" <pgsql-jdbc(at)postgresql(dot)org> |
Subject: | Re: Please help with binary file |
Date: | 2003-07-02 12:41:48 |
Message-ID: | 20030702134148.A4651@bacon |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-jdbc |
On 02/07/2003 06:38 Akash Shah wrote:
> Hi ,
>
> I am trying to upload binary file to the PostgreSQL 7.3.2 with JDBC3
> driver
> supplied by postgresql (pg73jdbc3). The table to which I am trying to
> save
> the file has a field of OID datatype. And while doing so I get
>
> "java.sql.SQLException: ERROR: oidin.............." error.
>
> I tried changing OID data type to bytea. After that code worked and I
> tried
> file sizes from 4KB to1.6 MB. If file size is larger than that ( even for
> a
> 10 MB size file ) execution just gets stuck. No error, no exception
> thrown.
Reaed the docs (5.6 Storing Binary Data). They give sample code of how to
use Large Objects with JDBC. I think this will do what you want.
HTH
--
Paul Thomas
+------------------------------+---------------------------------------------+
| Thomas Micro Systems Limited | Software Solutions for the Smaller
Business |
| Computer Consultants |
http://www.thomas-micro-systems-ltd.co.uk |
+------------------------------+---------------------------------------------+
From | Date | Subject | |
---|---|---|---|
Next Message | Fernando Nasser | 2003-07-02 12:58:53 | Re: Please help with binary file |
Previous Message | Patric Bechtel | 2003-07-02 08:51:49 | Re: db [Viruschecked] |