dimitri / dimitri/pgloader

Need for something in between BEFORE LOAD and AFTER SCHEMA CREATE

Open
#1,013 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Sponsor needed WishList
Dominant language
Common Lisp
Stars
6.5k
Forks
613
Avg merge
3h 46m
Merged PRs (30d)
1

Description

Rationale is following:

If you run pgloader with drop schema, whatever schema modifications are done in BEFORE LOAD are gone after the schema is dropped.

If you put them in AFTER SCHEMA CREATE, they will have no effect on things happening during the schema creation.

For example, if you need to create an extension in the schema that makes a new data type, and include that datatype into a casting rule, the extension has to be installed into the schema prior to creation of tables, but after the schema has been created.

You can of course hardcode your schema deletion in BEFORE LOAD itself, but that seem to obviate the point of automating this process.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing pgloader's handling of the BEFORE LOAD and AFTER SCHEMA CREATE phases, especially what happens when drop schema is enabled. Determine where a hook between schema creation and table creation would fit, then verify that an extension-created data type is available during table creation and casting-rule processing.

Written by the indexing model from the issue text.

Assessment

Tech stack
postgresql
Domain
databases
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
28/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.