I'm tring to create or update postgresql sequence with variable
If I put exact value when I create or update sequence, It works
like create sequence test minvalue 5 maxvalue 10 start 5;
but If I create some function which set min and maxvalue of sequence like
CREATE OR REPLACE FUNCTION test(bigint, bigint)
RETURNS void AS
$BODY$
BEGIN
create sequence test minvalue $1 maxvalue $2 start $1;
END;
$BODY$
LANGUAGE plpgsql VOLATILE
COST 100;
It makes errors
I'm searching to find the way to put the variable when I create sequence
who knows the way? please help.
I just want to create sequence range