Hi,
I am working on upload into database and download from database application.
It is working fine with <4K. but If it is > 4K it is closing the connection
by
The exception is thrown on the 'con.close()'.
Here is is the simple code..
java.io.File f = new java.io.File(fullpath);
FileInputStream fis = new FileInputStream(f);
PreparedStatement pstmt = con.prepareStatement("insert into MP1.TBL_UPLOAD
values (?,?,?)");
pstmt.setInt(1,114);
pstmt.setString(2, filename);
pstmt.setBinaryStream(3, fis, (int)f.length());
pstmt.executeUpdate();
pstmt.close();
con.close();
Please any one help me .. I stuck in this problem. Please do needful, I
will thankful to u.
Thanks,
Malla Reddy
[EMAIL PROTECTED]
_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html
http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets