
DB2
鸿风
爱好编程!
展开
-
DB2 SQL Error: SQLCODE=-668, SQLSTATE=57016, SQLERRMC=7;
SQLSTATE 57016: 因为表不活动,所以不能对其进行访问。 解决方法为:执行命令:reorg table XXX;即可。转载 2011-08-31 17:19:08 · 18462 阅读 · 0 评论 -
ejb3 之 主键 生成 之 Sequence
在一些特殊的数据库中,比如Oracle中可以使用Sequence来生成自动主键。若要在Entity中使用Sequence作为主键的生成策略,则步骤如下所示。 (1)在数据库中创建一个Sequence,SQL脚本如下。 CREATE SEQUENCE customer_sequence START WITH 1 INCREMENT BY 10; 这个Sequence从1开始,每次增长10。转载 2011-12-15 16:31:18 · 1175 阅读 · 0 评论 -
复制表结构
Sql server : select * into table_new from table_old ; 复制结构和数据 select * into table_new from table_old where 1=2;只复制结构 Oracle: create table table_new as select * from table_old;复制结构和数转载 2012-02-29 10:57:03 · 1915 阅读 · 0 评论