You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Upgrading from gorm v1.22.5 columns of type serial does not appear to increment appropriately. According to the logs, with the new version of gorm and the gorm postgres driver, 0 is inserted in the serial column as opposed to the previous version where nothing is inserted and the column default sequence is correctly used.
GORM Playground Link
go-gorm/playground#439
Description
Upgrading from gorm v1.22.5 columns of type
serial
does not appear to increment appropriately. According to the logs, with the new version of gorm and the gorm postgres driver, 0 is inserted in the serial column as opposed to the previous version where nothing is inserted and the column default sequence is correctly used.gorm v1.3.0, postgress driver v1.3.0:
INSERT INTO "tests" ("created_at","updated_at","deleted_at") VALUES ('2022-02-22 12:51:00.618','2022-02-22 12:51:00.618',NULL) RETURNING "id"
gorm v1.22.5, postgress driver v1.2.3:
INSERT INTO "tests" ("id","created_at","updated_at","deleted_at") VALUES (0,'2022-02-22 12:52:02.765','2022-02-22 12:52:02.765',NULL)
The text was updated successfully, but these errors were encountered: