I have created an sqlite database file using sqlite browser.I have a file "sample.sqlite", now i wanted to know how to import this file in javascript and use the data in the sqlite file.I have been using this below mentioned script
var db;
try {
if (window.openDatabase) {
db = openDatabase("sample.sqlite", "1.0", "HTML5 Database API example", 200000);
if (!db)
alert("Error Failed to open the database, check version");
} else
alert("Error Not supported? Not gonna happen");
} catch(err) {}
By using this code i am not able to get the data from sqlite file.Please suggest me how to proceed.i have seen some sites where steps have been mentioned to create table,insert data by writing code in java script itself.But i don't know to do it that way i want to import the existing sqlite file.
i am not able to get the data.