Questions tagged [web-sql]

Web SQL Database is a SQL-based API allowing a web pages to store and retrieve structured data locally. It is based on, but not the same as SQLite.

Web SQL Database is a SQL-based API allowing web browsers/extensions/apps to store structured data locally. It is based on SQLite and, in practice, has been implemented solely on SQLite.

The API is currently supported by Google Chrome, Opera and Safari. But, The W3C has abandoned Web SQL in favor of Web Storage and the Indexed Database API. From the Web SQL spec:

... specification work has stopped. The specification reached an impasse: all interested implementors have used the same SQL backend (SQLite), but we need multiple independent implementations to proceed along a standardisation path.

Mozilla will not implement Web SQL DB, opting to implement IndexedDB instead, and Microsoft has hinted that they are more likely to implement IndexedDB than Web SQL.

Resources

855 questions
5
votes
1 answer

Working with WebSQL. How to add new column to existing table?

I have simple WebSQL database with 1 table and 3 columns. I would like to add one more column, but I can't do it if the database already exist. It's only possible after I have cleaned it in the cache, but then I'm loosing all the data. How can I add…
sergey_c
  • 741
  • 9
  • 14
5
votes
2 answers

How to get the context of a Web Sql error?

I start deploying an offline application on iPhones, but it's still under heavy developpment. I have a simple error handler for my query : db.transaction(tx) { tx.executeSql("SELECT * FROM TABLE",[], successHandler, errorHandler); }); function…
Matthieu
  • 563
  • 1
  • 7
  • 25
5
votes
2 answers

Pass extra parameters to WebSQL callback function?

I am calling a function db.transaction with following code: db.transaction(createSheetDB, function(){alert("Sheet creation error!")}, function(){alert("Sheet created!")}); The function createSheetDB is a callback function which is implicitly…
Balkrishna Rawool
  • 1,865
  • 3
  • 21
  • 35
5
votes
1 answer

Chrome Extension WebSQL - need background & content pages to access same database, but they Don't

I am currently working on a small extension for Chrome. I need same websql database for the extension, but I get different databases based on where I create them. If I create the database in the content page, I get the database created for a…
5
votes
3 answers

What is the maximum size of a Web SQL DB in iOS (Safari) on the iPad? How about LocalStorage?

What is the maximum data size when using HTML5's Web SQL to store data locally on the iPad? When you reach that, does it just prompt the user to increase it? Is that a simple yes/no permission request? If so, what's the hard limit (beyond which…
Clay Nichols
  • 11,848
  • 30
  • 109
  • 170
4
votes
1 answer

How to stop the HTML 5 database from being deleted in iOS 5.1

This is basically the same question as this one, except that I'm not using PhoneGap (so I don't think any of the solutions offered there are applicable). I have a pure HTML/JS webapp that works offline (using WebSQL for storage, and AppCache for…
Scott
  • 1,518
  • 1
  • 15
  • 23
4
votes
3 answers

accessing the same web sql database from a web worker and the main browser thread

I have googled quite a bit and cannot find out whether I should be able to access the same websql database from the main ui thread and a web worker. I am using the async api since I believe this is the only API that has been implemented for both the…
paul
  • 494
  • 6
  • 17
4
votes
1 answer

Finding the size of an HTML 5 web sql database size after creation

I'm using HTML 5 Web SQL database in Safari. I'm setting the database size to 5 MB. After creating database the size increased, but I can't find out the new size of the database. Where can I find the size of the database after creation?
Ramasamy Kanna
  • 794
  • 3
  • 11
  • 32
4
votes
1 answer

Use Delphi+Intraweb to create HTML5 offline application (cache manifest) with browser storage (webSQL/IndexedDB) possible?

My current Intraweb application is actually a DataSnap Client which connect to my DataSnap Server that connects and sits together with an Interbase Server on the same machine. It works correctly but quite slow and require constant Internet…
Colin Jong
  • 63
  • 1
  • 6
4
votes
1 answer

Does WebSQL support primary keys?

I'm creating a WebSQL table in Chrome with the following statement: 'CREATE TABLE IF NOT EXISTS recs(id, fname,lname,email,country,comments, synced integer,PRIMARY KEY(id))' Inserting records does not appear to be creating primary keys. How…
Fred
  • 3,786
  • 7
  • 41
  • 52
4
votes
2 answers

Alternatives to using Web SQL database for storing large amount of data in Phonegap app?

Problem Statement :- 1) The app is developed in Phonegap to support multiple devices (Android,iOS etc) 2) Currently using Web SQL database due to large amount of data 3) App will have to receive updated data and update its database, in the near…
ilight
  • 1,622
  • 2
  • 22
  • 44
4
votes
2 answers

Trouble with iOS and PhoneGap

Just started trying to adapt my html, css, javascript files to iOS using PhoneGap (I've also tried NimbleKit but the result is the same). I have a web app that I originally wrote for the Blackberry Playbook. The app works fine on the Playbook and…
robert smith
  • 861
  • 2
  • 10
  • 17
4
votes
1 answer

Run a PRAGMA command in WebSQL

Is there any way to run a PRAGMA command from WebSQL? PRAGMA is defined in the SQLite documentation, but doesn't seem to work in WebSQL.
Varun Singh
  • 1,676
  • 3
  • 18
  • 25
4
votes
3 answers

WebSQL chrome admin tool

I am building an app using a web SQL database. I remember seeing somewhere that there is a way using Google Chrome to inspect the web SQL databases, however I can't find the correct way of doing this.
Petran
  • 7,677
  • 22
  • 65
  • 104
4
votes
1 answer

localForage storage capacity

I'm using localForage in my Cordova application. I want to know the size of the localforage. Basically it is mentioned as 5mb limit. I will have more than 100mb data in my mobile application. var DefaultConfig = { description: '', driver:…