You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by bu...@apache.org on 2009/04/15 15:10:20 UTC
DO NOT REPLY [Bug 47036] New: java.lang.ClassCastException:
org.apache.tomcat.dbcp.dbcp.DelegatingResultSet
https://issues.apache.org/bugzilla/show_bug.cgi?id=47036
Summary: java.lang.ClassCastException:
org.apache.tomcat.dbcp.dbcp.DelegatingResultSet
Product: Tomcat 5
Version: 5.5.27
Platform: PC
OS/Version: Windows XP
Status: NEW
Severity: blocker
Priority: P1
Component: Catalina
AssignedTo: dev@tomcat.apache.org
ReportedBy: ydkalyan@gmail.com
CC: ydkalyan@gmail.com
java.lang.ClassCastException: org.apache.tomcat.dbcp.dbcp.DelegatingResultSet
i am facing this exception while doing the upload file functionality
please find the code which i am using for storing the binary information in the
table
kindly give me any solution to overcome this issue. thanks in advance
private void storeBlob(Connection con, long lngNattId, InputStream input,long
nboId) throws SQLException, IOException {
PreparedStatement pStmt = null;
ResultSet rs = null;
OutputStream out = null;
pStmt = con.prepareStatement("SELECT * FROM ATTACHMENT WHERE ATT_ID = ? FOR
UPDATE ");
pStmt.setLong(1, lngNattId);
rs = pStmt.executeQuery();
rs.next();
DelegatingResultSet dRS = (DelegatingResultSet) rs;
OracleResultSet oRS = (OracleResultSet) dRS.getInnermostDelegate();
out = (oRS.getBLOB("NATT_BIN_FILE")).getBinaryOutputStream();
byte[] buffer = new byte[32768];
int n = 0;
while ((n = input.read(buffer)) != -1) {
out.write(buffer, 0, n);
}
out.flush();
con.commit();
}
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org
DO NOT REPLY [Bug 47036] java.lang.ClassCastException:
org.apache.tomcat.dbcp.dbcp.DelegatingResultSet
Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=47036
Mark Thomas <ma...@apache.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|REOPENED |RESOLVED
Resolution| |INVALID
--- Comment #3 from Mark Thomas <ma...@apache.org> 2009-04-15 07:46:14 PST ---
Again, use the users list.
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org
DO NOT REPLY [Bug 47036] java.lang.ClassCastException:
org.apache.tomcat.dbcp.dbcp.DelegatingResultSet
Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=47036
Mark Thomas <ma...@apache.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |INVALID
--- Comment #1 from Mark Thomas <ma...@apache.org> 2009-04-15 06:39:55 PST ---
That is a question for the users list.
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org
DO NOT REPLY [Bug 47036] java.lang.ClassCastException:
org.apache.tomcat.dbcp.dbcp.DelegatingResultSet
Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=47036
ydkalyan <yd...@gmail.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |REOPENED
Resolution|INVALID |
--- Comment #2 from ydkalyan <yd...@gmail.com> 2009-04-15 07:43:13 PST ---
kindly provide me any solution. thanks for your great help
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org