摘要:
1 --SQL SERVER中的流水号创建2 create table books3 (4 no int identity(1,11),5 bid as right(replicate('0',5) + cast([no] as varchar),6),6 [name] varchar(50)7 );8 insert into books(name) values('t1'); 阅读全文
摘要:
1 --创建表 2 create table test 3 ( 4 id number primary key, 5 name varchar2 not null 6 ); 7 --创建序列 8 create sequence test_seq 9 start with 1 increment by 1;10 11 --创建触发器12 create or replace trigger tri_test_zz13 before insert on test14 for each row15 begin16 select test_seq.nextval into :new.i... 阅读全文