简单的类型转换问题
String start = "";
DbOperator dbp = new DbOperator();
ResultSet rs = null;
String sql = "select accept_date from xu_qcdl_basic where agent_code=" + qId + "";
// String caseName = "";
try {
rs = dbp.exeSingleSearch(sql);
if (rs != null) {
while (rs.next()) {
start = rs.getString("accept_date");
}
}
}
catch (Exception e) {
log.error(e.getMessage());
throw new RuntimeException("error.user.unexpect");
}
/////////////////////////////////////////
SimpleDateFormat sdf = new SimpleDateFormat("yyyy/M/d");
Date startDate = sdf.parse(start);
上面的start类型和下面的转换不匹配,我要用下面的类型,请问上面怎么改