Re: Should the DBI layer be query language agnostic, even completely "ignorant"?
Lassi Kortela 20 Sep 2019 12:06 UTC
> That's indeed my point, and those two non-SQL databases, plus we assume the in-progress Graph Query Language (GQL), match the SQL interaction shape, including columns having names. Which we can be sure is No Accident.
I don't know much about graph databases in general, but GraphQL query
results have a completely different structure from SQL query results.
It's hierarchical (literally JSON, basically) instead of tabular.
Document databases like CouchDB can be expected to hit the same issue.
IIRC they also return hierarchical results, or at least some of them.
> Strongly suggesting my project will be (re-)named sdbi for Scheme Database Interface
This is a tangential nit, but I'd avoid inventing new acronyms where
possible. A Scheme Database Interface could be called just "database",
since you always call it from Scheme, and anything you can call is an
interface. So procedures named like "database-connect" (or abbreviated
"db-connect") would be clearer than "sdbi-connect".
Using a generic name like "database" has the added benefit that it
discourages people from making slightly different APIs for the same
task; if the obvious name is already reserved, it sends a strong signal
that this is the official one (even if it isn't officially official :)