Skip to content

Automatically Generating Types for Tables with Large Numbers of Columns #238

Closed Answered by ocharles
idontgetoutmuch asked this question in Q&A
Discussion options

You must be logged in to vote

PostgreSQL has all information about tables itself as metadata tables. What I tend to do is to query this metadata in a SELECT statement, and I format it with a bunch of string_agg and stuff so that it actually produces Haskell. Have a look at #59, which I think shows some of these metadata tables. Infact, that very PR might do the job for you.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@idontgetoutmuch
Comment options

Answer selected by idontgetoutmuch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants