|
Deepa Remesh made changes - 13/Jul/05 01:47 AM
Deepa Remesh made changes - 14/Jul/05 10:27 AM
Committed revision 219259.
Daniel John Debrunner made changes - 16/Jul/05 08:12 AM
Deepa Remesh made changes - 16/Jul/05 09:21 AM
Deepa Remesh made changes - 16/Jul/05 09:21 AM
This patch can be applied to 10.1 branch also.
Deepa Remesh made changes - 30/Aug/05 04:14 AM
Fixed in 10.1 branch with revision 265639.
Kathey Marsden made changes - 01/Sep/05 12:43 PM
Deepa Remesh made changes - 02/Sep/05 10:16 AM
Deepa Remesh made changes - 30/Sep/05 02:18 AM
reopening to fix fix version
Deepa Remesh made changes - 30/Sep/05 02:19 AM
Deepa Remesh made changes - 30/Sep/05 02:19 AM
Kathey Marsden made changes - 01/Dec/05 04:05 PM
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
The code snippet which was throwing the exception is below:
//convert resultset data to string array
public String[] getOneRowAtATime(ResultSet rs) throws Exception {
int columnCount = exportResultSetForObject.getColumnCount();
ResultSetMetaData rsm=rs.getMetaData();
if (rs.next()){
String[] rowObjects = new String[columnCount];
for (int colNum = 0; colNum < columnCount; colNum++) {
if (rs.getObject(colNum + 1) != null)
{
rowObjects[colNum]=rs.getString(colNum + 1);
}
}
return rowObjects;
}
In J2ME/Foundation, this was throwing an exception because getObject on DECIMAL types is not supported. I removed the call to getObject since it was a redundant check. getString internally checks for null values. The new code is below:
//convert resultset data to string array
public String[] getOneRowAtATime(ResultSet rs) throws Exception {
int columnCount = exportResultSetForObject.getColumnCount();
ResultSetMetaData rsm=rs.getMetaData();
if (rs.next()){
String[] rowObjects = new String[columnCount];
for (int colNum = 0; colNum < columnCount; colNum++) {
rowObjects[colNum]=rs.getString(colNum + 1);
}
return rowObjects;
}
The following tests now pass in J2ME/FP. I have removed the excludes for them:
tools/importExport.java
tools/importExportThruIJ.sql
tools/ieptests.sql
Ran derbyall with Sun Java 1.4.2 and IBM WCTME 5.7 Foundation Profile. One testcase failed in the latter. The failure is not related to this change.
Please review this patch and commit it.
Thanks,
Deepa