SQL was invented as a way to let “managers” (or more broadly, people who are not coders) extract information from databases.
Obviously, this was a good idea. Another good idea would have been to publish an interface that standardized programmatic access to the database. That layer has to exist somewhere, and if an API had been made available that incorporated the same abstractions as SQL does, odds are that it would have caught on just like SQL did. Over the years it would have become a standard, vendors would have competed to get their extensions accepted into the standard, and as object store databases and key-value databases emerged, the standard would be extended to embrace them.
Instead, we have hundreds, probably thousands of “database abstraction” layers that convert a programmer’s requirement into a SQL statement, thus making SQL itself the de-facto API. The query then gets parsed by the database server into something that must closely parallel the calls that went into the abstraction layer.
If SQL had come with a database access API that paralleled the query language, millions of developer hours would have been saved, let alone uncountable machine cycles. And maybe, just maybe, that API would have abstracted the nature of the back end database, so we’d have a single, unified API for interacting with “things that store data”, including filesystems.
What a lost opportunity.
Recent Comments