
数据库
wanghuanqiufly
这个作者很懒,什么都没留下…
展开
-
DB2 和 SQLserver查询锁的表及解锁
DB2:SELECT agent_id,table_name FROM TABLE (SNAPSHOT_LOCK('EBANK',-1)) AS LOCK where table_name is not nullFORCE APPLICATION(agent_id);SQLServer:select request_session_id spid, OBJECT_N...2012-04-27 10:24:10 · 656 阅读 · 0 评论 -
将数据库二进制流转为本地文件
将数据库中存储的二进制转换为本地文件,前提需要知道文件类型Statement st = conn.createStatement(); ResultSet rs = st.executeQuery(sql); File file = new File("ff."+filetype); OutputStream output = new FileOutputStream(fil...2012-08-01 09:52:22 · 634 阅读 · 0 评论 -
JDBC获取表字段名称
List columnNameList = new ArrayList(); ResultSet rs = conn.getMetaData().getColumns(null, null, tableName, "%"); while(rs.next()) { columnNameList.add(...2012-08-30 09:49:07 · 425 阅读 · 0 评论