mirror of
https://github.com/dimitri/pgloader.git
synced 2026-05-05 19:06:11 +02:00
Fix the PostgreSQL Reset Sequences code.
This commit is contained in:
parent
314ee9611a
commit
236c9ffdf5
@ -572,7 +572,8 @@ order by ordinal_position" dbname table-name)))
|
||||
(mapcar
|
||||
(lambda (name) (apply-identifier-case name identifier-case))
|
||||
only-tables)))
|
||||
(pgloader.pgsql:reset-all-sequences pg-dbname :only-tables only-tables)))
|
||||
(log-message :notice "Resetting all sequences")
|
||||
(pgloader.pgsql:reset-all-sequences pg-dbname :only-tables only-tables)))
|
||||
|
||||
;; now end the kernels
|
||||
(let ((lp:*kernel* idx-kernel)) (lp:end-kernel))
|
||||
|
||||
@ -151,7 +151,7 @@ BEGIN
|
||||
and a.atthasdef
|
||||
WHERE relkind = 'r' and a.attnum > 0
|
||||
and pg_get_expr(d.adbin, d.adrelid) ~~ '^nextval'
|
||||
~@[and c.oid in ~{'~a'::regclass~^, ~}~]
|
||||
~@[and c.oid in (~{'~a'::regclass~^, ~})~]
|
||||
LOOP
|
||||
n := n + 1;
|
||||
EXECUTE r.sql;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user