摘要:
DB2中批量导出Sequence 如下脚本,可以将某个用户的全部sequence查询出来,并拼成创建语句。 代码如下:select 'CREATE OR REPLACE SEQUENCE ' ||SEQNAME|| ' AS INT '|| ( case when LASTASSIGNEDVAL IS NULL then ' START WITH '||CHAR(BIGINT(START)+1) else ' START WITH '||CHAR(BIGINT(LASTASSIGNEDVAL)+1) end)|| ' IN 阅读全文