Improve error handling for pkeys creation.

When creating the primary keys on top of the unique indexes, we might
still have errors (e.g. with NULL values). Make it so that a failure in
one pkey doesn't fail every other one, by having them all run within a
single connection rather than a single transaction.
This commit is contained in:
Dimitri Fontaine 2016-01-12 14:53:42 +01:00
parent 133028f58d
commit 2c200f5747

View File

@ -73,7 +73,7 @@
(when reset-sequences
(reset-sequences catalog :pgconn (clone-connection (target-db copy))))
(with-pgsql-transaction (:pgconn (clone-connection (target-db copy)))
(with-pgsql-connection ((clone-connection (target-db copy)))
;;
;; Turn UNIQUE indexes into PRIMARY KEYS now
;;