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

WIP: Add schema-to-rel8 #59

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

WIP: Add schema-to-rel8 #59

wants to merge 3 commits into from

Conversation

ocharles
Copy link
Contributor

@ocharles ocharles commented Jun 19, 2021

This executable takes a database connection string and a schema name, and prints out Haskell code to STDOUT that defines all data types along with corresponding TableSchemas.

For example:

cabal run schema-to-rel8 -- --connection="dbname=foo user=bar" --schema="public"

ocharles and others added 3 commits June 19, 2021 16:44
This executable takes a database connection string and a schema name,
and prints out Haskell code to STDOUT that defines all `data` types
along with corresponding `TableSchema`s.
@peterwicksstringfield
Copy link

peterwicksstringfield commented Oct 21, 2022

Hi, drive by contribution here, because I was messing with rel8 and ended up using your script.

  1. Bugfix: the script was using the table name in place of the schema name.
  2. Suggested, but questionable, improvement: deduplicate the definition of the field name. I'm not attached to this commit at all.

#210

FYI I think this script is findable and useful even if just sits here in this PR forever.

Thanks,

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants