
数据库
文章平均质量分 62
myicer
这个作者很懒,什么都没留下…
展开
-
学习笔记:DB2 V9 管理 - 6
学习笔记:DB2 V9 管理 - 62006-12-22 17:05 ...2007-01-26 18:37:00 · 161 阅读 · 0 评论 -
Oracle中Number类型数据说明
number类型有些困惑,google之后,摘录如下:number(p, s):1、绝对是 p > s, or error;2、所存储的数据整数位数肯定小于p;可能有理解误差 ^_^Digest below:------------------------------number(p,s) p:1~38 s:-84~127最高整数位数=p-ss...原创 2008-12-09 16:40:59 · 610 阅读 · 0 评论 -
jdbcTemplate.queryForList()操作读取Date型的方法
sql = "select tname, c_date from t_table";t_name :varchar2 ; c_date dateList rs = jdbcTemplate.queryForList(sql);则在读取list中数据时如下:Iterator iterator = rs.iterator(); while(iterator.hasNext()){ M...2008-05-09 14:00:27 · 5339 阅读 · 1 评论 -
connect by sql
一种SQL:[code="sql"]select id, level from tree t start with t.parent_id = 0 connect by prior t.id = t.parent_id; [/code]2008-04-17 17:01:34 · 117 阅读 · 0 评论 -
快速删除ORACLE重复记录
在Oracle中,可以通过唯一rowid实现删除重复记录;还可以建临时表来实现...这个只提到其中的几种简单实用的方法,希望可以和大家分享(以表employee为例)。 SQL> desc employee Name Null? Type emp_id NUMBER(10) emp_name VARCHAR2(20) salary NUMBE...2008-04-14 15:34:14 · 121 阅读 · 0 评论 -
Oracle新建用户,授权,建表空间
这段时间在学oracle,终于把公司的数据库成功导入到我自己的数据库里了。create用户sql 代码 1.[code="sql"] SQL> create user visiontv identified by visiontv default tablespace visiontv quota 10m on users; [/code] grant pri...2008-04-01 10:09:24 · 122 阅读 · 0 评论 -
数据库设计的范式大纲及一个小的实例说明
数据库设计的范式大纲 第一范式:对于表中的每一行,必须且仅仅有唯一的行值.在一行中的每一列仅有唯一的值并且具有原子性.第二范式:第二范式要求非主键列是主键的子集,非主键列活动必须完全依赖整个主键。主键必须有唯一性的元素,一个主键可以由一个或更多的组成唯一值的列组成。一旦创建,主键无法改变,外键关联一个表的主键。主外键关联意味着一对多的关系.第三范式:...原创 2008-10-03 21:42:38 · 118 阅读 · 0 评论 -
"对只转发结果集的无效操作: first" - 异常
今天调用DbUtil类直接操作数据库,取得ResultSet,想判断其是否为空(sql中有exists判断有无相关记录),结果出现异常:[code="java"][ERROR] 2009-03-19 11:04:44 [http-8080-1] com.utils.DbUtil.executeSql(DbUtil.java:57)java.sql.SQLException: 对只转发结...原创 2009-03-19 11:38:21 · 875 阅读 · 0 评论 -
Before, after, each row and table level triggers
The goal of this page is to demonstrate the most important differences between before and after triggers as well as the differences between for each row and table level triggers. Before / for eac...原创 2008-07-29 09:26:33 · 184 阅读 · 0 评论 -
找回MySQL的root密码
1. [code="c"]C:\wamp\bin\mysql\mysql5.1.36>cd binC:\wamp\bin\mysql\mysql5.1.36\bin>dir Volume in drive C has no label. Volume Serial Number is 38DC-C60C Directory of C:\wamp\bin\mysql\...原创 2010-05-12 11:03:38 · 153 阅读 · 0 评论