什么是带参???
UPDATE product SET name = 'abc' WHERE commid =1 and rebate=5是不是指这里带参WHERE commid =1 and rebate=5 ?????????//?
UPDATE product SET name = 'abc' WHERE commid =1 and rebate=5是不是指这里带参WHERE commid =1 and rebate=5 ?????????//?
解决方案 »
- 我在本机上,想写一个java程序获取我本机的外网ip地址,如何搞?
- No unique bean of type [...] is defined: Unsatisfied dependency of type
- 救急!!JSP如何将多个TABLE 导入到一个excel文件当中去?
- struts中怎样从jsp页面传递参数到action
- 请问J2ME通过web service访问数据库能给些例子吗,学习学习
- httpd+tomcat如何设置一个servlet或struts action为web的欢迎页面???
- 请教:如何在一个htm页面中运行一个Bean
- 我有这些工具,但要如何使用呢
- 一个proPerties 问题,怎么解决,谢谢,在线等。
- TOMCAT4.1.24关闭时的信息,请问是不是正常关闭?
- 用javabean封装数据库连接?????
- 我想在win98下面配置JSP运行环境,可以吗?tomcat是什么?
createStatement()
Creates a Statement object for sending SQL statements to the database.
第二个方法
createStatement(int resultSetType, int resultSetConcurrency)
Creates a Statement object that will generate ResultSet objects with the given type and concurrency.
第三个方法
createStatement(int resultSetType, int resultSetConcurrency, int resultSetHoldability)
Creates a Statement object that will generate ResultSet objects with the given type, concurrency, and holdability. prepareStatement这个用法差不多
这个东西不应该问人的...应该自己看的...
结果集类型
ResultSet.TYPE_SCROLL_INSENSITIVE(可前后移,但对别人修改不敏感的,可以说是静态游标)
ResultSet.TYPE_SCROLL_SENSITIVE(对别人修改的敏感,动态游标)
ResultSet.TYPE_FORWARD_ONLY (只向前)(TYPE开头的)
int resultSetConcurrency
游标类型
ResultSet.CONCUR_UPDATABLE(可修改的)
ResultSet.CONCUR_READ_ONLY (只读的)int resultSetHoldability
提交方式吧(这个我不曾用过)
以上三个都的ResultSet的静态属性
Statement stmt = con.createStatement(
ResultSet.TYPE_SCROLL_INSENSITIVE,
ResultSet.CONCUR_UPDATABLE);这个例子就是定义了一个静态的,可更新的Statement
如果是
Statement stmt = con.createStatement();
就是一个只读只向前的了API上面说得很清楚...
好累啊.....