数据库连接语句自己写!!
String sql = "select * from tbl_user"
try{
PreparedStatement ps = con.PrepareStatement(sql)
ResultSet rs = ps.executeQuery()
if(rs.next()){
System.out.println("不为null")
}else{
System.out.println("null")
}
ps.close()
}catch(Exception err){}
finally{
try{
con.close()
}catch(Exception e){}
}
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)