Put an absolute path name for your filename.

You're probably opening up the database in the wrong directory, creating an 
empty DB, and thus "no such table".



In particular this happens when running from the IDE or via an Icon where the 
working directory is not set.



Michael D. Black

Senior Scientist

Advanced Analytics Directorate

Advanced GEOINT Solutions Operating Unit

Northrop Grumman Information Systems

________________________________
From: [email protected] [[email protected]] on 
behalf of Waltênio de Bessa Mendes [[email protected]]
Sent: Thursday, March 15, 2012 1:48 PM
To: [email protected]
Subject: EXT :[sqlite] Sqlite error message

Hi,

I need help when receive a message error *"could not prepare statement no
such table..." * when try
execute "*select*"  in the code:


   * var db = window.openDatabase("Biblia","","Database",100000);
    var tx;
    var sql = "select nome from LivroDaBiblia;";
$(document).ready(function() {
        db.transaction(
            function(tx, myArray) {
                tx.executeSql("SELECT nome FROM LivroDaBiblia", [],
                function(tx, result) {
                  for (i = 0; i < result.rows.length; i++) {
                      var nome = result.rows.item(i)['nome'];
                      //$('<li>X' + name + 'Y</li>').appendTO($('#LV1'));
                     // $('#LV1').append("<li><a
href='#page4'>123</a></li>");
                         $('#LV1').append("<li>123</li>");
                      }
                    }, errorHandler);
                }
            );
            function errorHandler(transaction, error) {
                    alert('Oops. Error was '+error.message+' (Code
'+error.code+')');
                  return false;
            };*
_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to