-
Notifications
You must be signed in to change notification settings - Fork 323
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
Connection and Materialization in the Database Library #1546
Conversation
23bddcf
to
e1f8725
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some changes are needed to land this. And some are pure trolling.
distribution/std-lib/Database/THIRD-PARTY/org.xerial.sqlite-jdbc-3.34.0/LICENSE
Show resolved
Hide resolved
distribution/std-lib/Database/THIRD-PARTY/org.xerial.sqlite-jdbc-3.34.0/LICENSE
Show resolved
Hide resolved
distribution/std-lib/Database/THIRD-PARTY/org.xerial.sqlite-jdbc-3.34.0/LICENSE.zentus
Show resolved
Hide resolved
@@ -43,14 +47,16 @@ type Table | |||
|
|||
Converts this table to a JSON structure. | |||
to_json : Json | |||
to_json = this.to_sql.to_json | |||
to_json = case this.internal_columns.is_empty of | |||
True -> "Table: no columns".to_json |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a very bad json representation. Use an object with fields or something like that, not "here's a random string"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
True -> "Table: no columns".to_json | |
True -> Json.from_pairs [["query", Nothing], ["message", "The table has no columns so a query cannot be generated."]] |
Does this make sense?
ba42fcf
to
57685b4
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add the missing comments.
TODO: materialization counting rows
(but it doesn't work yet)
463d493
to
796e922
Compare
Pull Request Description
Related to #1351
Includes the functionality for connecting to the databases and materializing results of queries.
Important Notes
Checklist
Please include the following checklist in your PR: