Since November 18, 2010, the W3C announced that Web SQL database(Sqlite) is a deprecated specification. This is a recommendation for web developers to no longer use the technology as effectively, the spec will receive no new updates and browser vendors aren’t encouraged to support this technology. The new alternative is IndexedDB which is already available on Chrome 12+ and Firefox 5+, and, soon, in IE 10 as well.
The new web database standards adoption progress report as per Html5Test.com – how standards setting can work well.
- WebKit browsers originally shipped a copy of the SQLite — an embedded relational database — and then proposed “WebSQL” as a specification to standardize it.
- Mozilla objected to its standardization on the grounds that the SQL 92 standard was a poor basis for a web standards technology, and that an implementation (SQLite) shouldn’t be the basis for standard.
- As a result, WebSQL standardization was abandoned in favor of a new database standard, IndexedDB which is now the standard database of record for all major browsers.
- Firefox, IE and Chrome now support IndexedDB on the desktop.
- Chrome for Android is the first browser to support it on mobile devices.
|Advantages||A real, relational database implementation on the client (SQLite).||* Allows fast indexing and searching of objects, so in a web application scenario, you can manage your data and read/write it fast.
|Disadvantages||* The spec is deprecated.
* Not object driven
|Harder to understand if you are coming from the world of relational databases.|
|Query Mechanism||SQL||Cursor APIs, Key Range APIs, and Application Code|
|Transaction||Lock can happen on databases, tables, or rows on ‘readwrite’ transactions||Lock can happen on database ‘versionchange’ transaction, on an objectStore ‘readonly’ and ‘readwrite’ transactions.|
|Transaction Commits||Transaction creation is explicit. Default is to rollback unless we call commit.||Transaction creation is explicit. Default is to commit unless we call abort or there is an error that is not caught.|
http://html5test.com/compare/feature/storage-sqlDatabase.html ( WebSQL – Current Support on browsers)
http://html5test.com/compare/feature/storage-indexedDB.html ( IndexDB – Current Support on browsers)