3 ms·
> indexedDb is an API. This API is more primitive and limited than SQL. This API is basically a key value store with indices and transactions. This is what many
by throw_m239339 5y ago
> indexedDb is an API. This API is more primitive and limited than SQL. This API is basically a key value store with indices and transactions. This is what many SQL databases are implemented on top of (Postgres for example).
SQL isn't an API. It's a language. Something to query a SQL database in the browser would constitute the API (thus WebSQL). You are mixing up language and API here. That's your first mistake.
> So yes it is absolutely possible to implement a SQL database on top of indexed DB, and that would be the architecturally logical thing to do.
And it's trivial to implement indexedDB over Sqlite, in fact, that's what Firefox did.
Where is the other way around? Where are RDBMS implemented on top of indexedDB?
> The fact that Firefox goes the other way around is an implementation detail.
No it isn't. It demonstrates my point entirely, that it is trivial to implement indexedDB on top of Sqlite, which makes Mozilla developers a bunch of hypocrites for not letting developers access an Sql layer directly.
- crubier 5y agoOk, look, I disagree. I'll let you try to reconcile yourself about why "Mozilla developers are a bunch of hypocrites". I presented to you a very straightforward explanation that does not imply bad intent from an entire group of people. I am sorry that this explanation does not fit your world view. To me, what you say is the equivalent of saying « assembly is higher level than JavaScript because someone implemented a virtual machine that runs assembly code, in JavaScript in the browser ». Just because someone at Mozilla used this technique for some technical reason (it is indeed often easier to emulate low level stuff on top of high level stuff, rather than the opposite) does not change the fact that IndexedDB is an API, is not built on top of SQLite, and is lower level than any API based SQL.
- deleted 5y ago[deleted]