Bigzhu's den

postgresql update sequences

bigzhu
SELECT setval('your_table_id_seq', COALESCE((SELECT MAX(id)+1 FROM your_table), 1), false);
bigzhu
Everything is learnable