6 ms·
If everything you said is accurate, somebody should make another pitch for WebSQL ( https://en.wikipedia.org/wiki/Web_SQL_Database https://en.wikipedia.org/wiki
by webmobdev 6y ago
If everything you said is accurate, somebody should make another pitch for WebSQL ( https://en.wikipedia.org/wiki/Web_SQL_Database https://en.wikipedia.org/wiki/Web_SQL_Database ) with a custom version of DuckDb!
Every browser maker was interested in implementing it but the W3C couldn't go ahead with it because everyone chose to implement it using SQLite, where as W3C required more than one db back-end implementation to move forward.
- wffurr 6y agoHaving sqlite included in all browsers with standard bindings would have been great.
- jansommer 6y agoIt would! But it would also be a security nightmare. Exploit SQLite and you could use it in Safari, Chrome and Firefox - everybody could be affected.
- andyfleming 6y agoHow would that be different from someone editing something in window.localStorage?
- jansommer 6y agoIf that's all you need, it wouldn't make sense to include SQLite in the browser. If you're going to include a relational database you might as well use it
- CRConrad 6y agoI think that meant: How would that be more of a security nightmare than some malicious site editing your browser's whatever.localstorage?
- hajile 6y agoIronically, all the IndexDB implementations were just thin layers on top of sqlite last I checked.
- WorldMaker 6y agoThe original slow IndexedDB implementations were done that way, but my understanding is that anything fast and "modern" probably isn't in 2020 as most of the browsers moved to their own IndexedDB storage implementations that are not SQLite-based. IndexedDB has very different expected performance characteristics than a pure relational DB (as it is a key/value store with indexes closer to most "NoSQL" DBs than to SQLite) and it did not (and does not) make long term sense to use SQLite below the hood.
- afiori 6y agoThis could work if there is a subset of SQL where duckDB and SQLite behave almost identically
- webmobdev 6y agoI often wondered why someone didn't do it with BerkleyDb too? I know Oracle owns it, but it is open source and someone like Mozilla could have implemented it in their browser just to get the W3C rolling on WebSQL.
- afiori 6y agoThe problem with WebSQL would remain the same, it would be necessary to specify a subset of SQL as a web standard.