mirror of
https://github.com/dimitri/pgloader.git
synced 2026-01-21 23:21:12 +01:00
With the new internal setting *copy-batch-size* it's now possible to instruct pgloader to close batches early (before *copy-batch-rows* limit) when crossing the byte count threshold. When set to 20 MB it allows the new test case (exhausted) to pass under SBCL and CCL, and there's no measurable cost when *copy-batch-size* is set to nil (its default value) in the testing done. This patch is published without any way to tune the values from the command language yet, that's the next step once its been proven effective.
16 lines
652 B
Fish
16 lines
652 B
Fish
LOAD DATABASE
|
|
FROM mysql://root@localhost:3306/exhausted
|
|
INTO postgresql:///exhausted
|
|
|
|
WITH include drop, create tables, create indexes, reset sequences, truncate
|
|
|
|
CAST type datetime to timestamptz drop default drop not null using zero-dates-to-null,
|
|
type date drop not null drop default using zero-dates-to-null,
|
|
type timestamp to timestamptz drop not null using zero-dates-to-null,
|
|
|
|
-- now the default for tinyint(1)
|
|
-- column bools.a to boolean drop typemod using tinyint-to-boolean,
|
|
|
|
-- override char(1) to varchar(1), just use char(1) here.
|
|
type char when (= precision 1) to char keep typemod;
|