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 = 'RUBICWARE'
转载于:https://my.oschina.net/u/1241831/blog/383287