INSERT INTO newtable (year,medal) VALUES (1992,23), (1993,123), (1994,12), (1995,22), (1997,35), (1996,68); alter table newtable add idtest serial primary key; select * from newtable as n TRUNCATE TABLE newtable RESTART IDENTITY; > reset to zero (the idtest primarykey)