Am Dienstag, 23. Dezember 2003 15:43 schrieb Claire Wall:
> hi,

Oracle is different from other databases when it comes to LOBs
due to the LOB locator concept. IIRC you have to use the Oracle JDBC 
extensions for that (oracle.jdbc.*). Some links that may be helpful:

http://www.csee.umbc.edu/help/oracle8/java.815/a64685/
oraext4.htm#1043351
http://www.csee.umbc.edu/help/oracle8/java.815/a64685/samapp2.htm

Then, getting an InputStream from the FormFile and writing the
contents to the database via blob.getBinaryOutputStream() is
just routine. That's how we do it, at least, and it works perfectly
with the thin driver, too.

HTH,
-- Chris 

> I have a jsp page which uploads a file to a database. I have no
> problems storing the file in an SQLServer or MySQL database by using
> the setBinaryStream() method of a PreparedStatement. The file gets
> upload no problem.
>
> However, when I try to upload this file to an oracle database (BLOB
> column) it does not work. I'm sure that i have to use the setBlob()
> method of the PreparedStatement, however, my dilemma is that I cannot
> find a way to convert my file from FormFile format to sql Blob
> format. Does anybody know how to do this as I've looked everywhere
> and haven't come up with a solution.
>
> Any help would be much appreciated
>
>
> thanks
> claire


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to