Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add db schema #1799

Closed
wants to merge 3 commits into from
Closed

Add db schema #1799

wants to merge 3 commits into from

Conversation

Pierre-Louis-Boutruche
Copy link
Contributor

This is an addition to be able to use a specific schema with Postgres. We have modified the base.py files to be functional with a specific schema, we have also added the DATABASE_SCHEMA environment variable to be able to configure the schema. By default the variable is none so the program will take the public schema.

@satterly satterly force-pushed the master branch 2 times, most recently from d73641a to 4cdfcfb Compare February 27, 2023 23:14
register_composite(
'history',
name,
conn,
globally=True
)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Replace this with ...

register_composite(
            schema + '.history' if schema else 'history',
            conn,
            globally=True
        )

@satterly
Copy link
Member

satterly commented Mar 1, 2023

Please address the above comments and add some tests to ensure setting a schema works as expected. Thanks.

@satterly satterly added the needs work This pull request needs work label Mar 1, 2023
@satterly
Copy link
Member

satterly commented Mar 1, 2023

Btw, you will need to rebase with master so that the tests run.

@Pierre-Louis-Boutruche Pierre-Louis-Boutruche closed this by deleting the head repository Apr 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs work This pull request needs work
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants