rs = stmt.executeQuery
("select detail from tb_file where name='aaa.gif' for upfdate" );
if(rs.next()) { Blob blob = rs.getBlob(1);
BinaryOutputStream out =
((oracle.sql.BLOB)blob).getBinaryOutputStream();
byte[] b = new byte[((oracle.sql.BLOB)blob).getBufferSize];
InputStream fin = new FileInputStream(file);
int len = 0; while( (len = fin.read(b)) != -1) out.write(b,0,len);
fin.close(); out.close(); conmit(); }