ALTER SEQUENCE eadmodulo_id_seq RESTART WITH 8;
alter sequence your_sequence restart with 1000;
SELECT setval('payments_id_seq', 21, true); # next value will be 22