I am trying to loop through sequences through a database link which I am doing fine. The issue I am getting is ORA-00933 "SQL command not properly ended". If I remove the min value from execute immediate it works perfectly fine. Whats wrong with my syntax?
This is my code:
Declare
CURSOR seqe IS
select sequence_name, min_value from dba_sequences@mylink
BEGIN
For i in seqe LOOP
execute immediate 'create sequence '||i.sequence_name|| ' min_value ' ||i.min_value;
END LOOP;
END;
>Solution :
There’s no underscore in MINVALUE