-- Create sequence
create sequence CHATACTIVITY_SEQ
minvalue 1
maxvalue 9999999999999999999999999999
start with 4583
increment by 1
create sequence CHATACTIVITY_SEQ
minvalue 1
maxvalue 9999999999999999999999999999
start with 4583
increment by 1
cache 20;
mysql 先创建 一个表
BEGIN
REPLACE INTO chatactivity_seq(stub) VALUES ('a');
RETURN (SELECT LAST_INSERT_ID() from dual);
END