I am trying to create a local database. I made some inserts, but when I run the code I get the "result = null" error:
var selectStmt:SQLStatement = new SQLStatement();
selectStmt.addEventListener(SQLErrorEvent.ERROR, dbErrorHandler);
selectStmt.sqlConnection = conn;
selectStmt.text = "SELECT * FROM table1";
selectStmt.execute();
var result:SQLResult = selectStmt.getResult();
var numResults:int = result.data.length;
How can I fix this?