怎么判断从数据库中查到的结果集为空??
解决方案 »
- 一个BT的面试题目求教~~~
- 怎么不字符串的内容作为另外一个类的引用???
- eclipse中怎样过滤掉所用的warning?
- 关于SOCKET端口被占用的问题!!!
- eclipse 的中文帮助文档
- 请高手帮我解决一个小问题!!!
- 问一下System.exit(0)与System.exit(1)有什么区别,里面的整数代表什么
- 如何为控件添加一个新的监听事件? 如为 JTextField 添加一个 TextChange 事件。
- 使用JB碰到的问题
- 请问,哪里可以下载一个体积最小的JAVA编译器?
- 这个问题让我嚼尽脑汁,我是束手无策啊,难怪是个新手啊,各位高手拉在下一把,快近来啊!!
- 程序如何实现适应不同语言环境?
或者你直接执行sql语句为"select count(*)..."判断是否为0就ok了
int getRow()
throws SQLExceptionRetrieves the current row number. The first row is number 1, the second number 2, and so on. Returns:
the current row number; 0 if there is no current row
Throws:
SQLException - if a database access error occurs
Since:
1.2
if(res.next()){
// todo:一些操作;
else
throw new Exception("没有数据");