1. 拼接生成序列的语句
select 'create sequence ' ||sequence_name|| ' minvalue ' ||min_value|| ' maxvalue ' ||max_value|| ' start with ' ||last_number|| ' increment by ' ||increment_by|| ( case when cache_size= 0 then ' nocache' else ' cache ' ||cache_size end) || ';' from dba_sequences where sequence_owner= 'DUBBO'; --用户名称要大写
2. 查询序列生成语句
select dbms_metadata.get_ddl('SEQUENCE',u.object_name) from user_objects u where object_type='SEQUENCE';