// allow field-conversion for discriminator column too
String result = (String) fld.getFieldConversion().sqlToJava(tmp);
result = result != null ? result.trim() : null;
if (result == null || result.length() == 0)
{
throw new PersistenceBrokerException(
"ojbConcreteClass field for class " + cld.getClassNameOfObject()
+ " returned null or 0-length string");
}
else
{
/*
arminw: Make sure that we don't read discriminator field twice from the ResultSet.
*/
row.put(fld.getColumnName(), result);
return result;
}
}
catch(SQLException e)
{
throw new PersistenceBrokerException("Unexpected error while try to read 'ojbConcretClass'" +
" field from result set using column name " + fld.getColumnName() + " main class" +
" was " + m_cld.getClassNameOfObject(), e);
}
}