aspose file tools*
The moose likes JDBC and the fly likes java.sql.exception : Failed to Convert Internal Representation Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of JavaScript Promises Essentials this week in the JavaScript forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "java.sql.exception : Failed to Convert Internal Representation" Watch "java.sql.exception : Failed to Convert Internal Representation" New topic
Author

java.sql.exception : Failed to Convert Internal Representation

Ajju Chawla
Greenhorn

Joined: Oct 21, 2005
Posts: 21
Hi,

Iam facing this strange problem after a got a new set of data.
Its a SQL exception with message "Failed to convert internal representation",
now what I could make out is that some part of the data is not compatible with my web application, may be jdbc is not able to take care of that particular data. The reason I think so is that the same query is nicley running and giving me results on Oracle client.

My env is -
1. Apache Tomcat 5.5.9
2. jdk-1_5_0_04-windows-i586-p
3. commons-dbcp-1.2.1
4. commons-pool-1.2

Any help is greatly appreciated.

Thanks
-Aj
Brian Mozhdehi
Ranch Hand

Joined: Aug 17, 2006
Posts: 81
Your result set call is trying to get a type that is not the same and not convert-able from the actual type. For example trying to get a varchar using rs.getInt().

Check out http://www.dbmotive.com/oracle_error_codes.php?errcode=17059

and then adjust your code accordingly. The stack trace of the error ought to tell you which column is the culprit and there, change rs.getWhatever to rs.get(The Correct Type)
Ajju Chawla
Greenhorn

Joined: Oct 21, 2005
Posts: 21
Hi Brian,

That was the problem..I was trying to get a VARCHAR with getLong().
Thanks
-Aj
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: java.sql.exception : Failed to Convert Internal Representation