Connection connection=DriverManager.getConnection(url,"sql_973","datashare");要放到try catch块里,因为可能会抛出ClassNotFoundExceptionrs=statement1.executeQuery(sql);也要放到try catch块里,因为可能会抛出SQLException
解决方案 »
- 怎样清理JAVA屏幕打印信息?
- JTextPane setPage 加载html文件后 垂直滚动条不能停在最下端,求解决方法
- Javax.mail发送邮件是否可以实现保存到发件箱
- 小菜奔泪啊、求大虾大婶帮看下我的代码错我,我咋就不会改呢?
- 定义一个LinkedList数组时出现NullPointerException
- RCP开发如何在程序启动时先出现一张图片,像JBUILD、SQLSever2005之类的软件
- 为什么答案是B
- 工资指数
- 用POI怎么在Excel中间(非末尾)插入新行?
- faint!我已经把jar包放入classpath,可是NoClassDefFoundError!
- 请问哪可下载<<JAVA2编程起步>>
- ias6.5中应如何配置sybase的database?
String sql="select * from se590_brdf where ob_date = \'" + ob_date + "\' and field_no = \'" + position + "\' and rtrim(ltrim(objection)) = \'冬小麦\' and " + sql_dire; //sql_dire是什么?
String sql2 = "select * from 土面反射率_BRDF where ob_date = \'" + ob_date + "\' and field_no = \'" + position+ "\' and ltrim(rtrim(beijing_time)) = \'" + bj_time + "\'";也就是说,在单引号'的前面都加上\
for (j=0;j<252;j++)
{
ref[0][j]=rs.getFloat(j+10) ; /********* 它可能会出错越届*******/
}
回答相关者给分