mirror of
https://github.com/dimitri/pgloader.git
synced 2026-05-04 18:36:12 +02:00
Fix support for discovery of DBF target table name.
When the LOAD command does not provide the name of the target table for a DBF source, we can get the name of the table from the DBF file itself. That feature got broken, here's a fix. Fix #805.
This commit is contained in:
parent
4cd26c09fd
commit
dfedce2aba
@ -107,7 +107,8 @@
|
||||
:target-db ,pg-db-conn
|
||||
:encoding ,encoding
|
||||
:source-db source-db
|
||||
:target (create-table ',target-table-name))))
|
||||
:target ,(when target-table-name
|
||||
(create-table target-table-name)))))
|
||||
|
||||
,(sql-code-block pg-db-conn :pre before "before load")
|
||||
|
||||
|
||||
@ -51,8 +51,8 @@
|
||||
(declare (ignore materialize-views only-tables create-indexes foreign-keys
|
||||
including excluding))
|
||||
(let* ((table (or (target db3) (source db3)))
|
||||
(schema (or (when (table-schema (target db3))
|
||||
(push-to-end (table-schema (target db3))
|
||||
(schema (or (when (table-schema table)
|
||||
(push-to-end (table-schema table)
|
||||
(catalog-schema-list catalog)))
|
||||
(add-schema catalog (table-name table)))))
|
||||
(push-to-end table (schema-table-list schema))
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user