A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: need help with SQLite database location

  1. #1
    Senior Member
    Join Date
    Mar 2005
    Posts
    154

    need help with SQLite database location

    Hi guys....kind of stuck up....really need help so bad here..
    here's the situation I'm developing Air application using flex builder 3 and of course using sqlite as my database...Everything is going ok so far...Except...Sqlite dtbase mngmnt really give me headache...because I dont have idea where to find my dtbase was created using code...fyi I'm using SQLite sorcerer Air application SQLITE dtbase mngmnt which is so great...so when i try to browse to see my database....I'm lost here...where exactly the database was place when we created using code ..so that I can manage the table using this SQLite sorcerer...

    code:

    conn = new SQLConnection();
    var dbFile:File = File.applicationStorageDirectory.resolvePath("DBSa mple.db");

    try{
    trace("database was created");
    conn.open(dbFile);

    }catch(error:SQLError){
    trace("Error message:", error.message);
    trace("Details:", error.details);
    }

    as well as to see my table also

    stmt = new SQLStatement();
    stmt.sqlConnection = conn;

    var sqlcreatetbl:String = "CREATE TABLE IF NOT EXISTS user (" +
    " userId INTEGER PRIMARY KEY AUTOINCREMENT, " +
    " test TEXT " +
    ")";
    stmt.text = sqlcreatetbl;
    try{
    stmt.execute();
    }catch(error:SQLError){
    trace("Error message:", error.message);
    trace("Details:", error.details);
    }




    Hope someone will shed me some light ...and sorry for this silly question...
    tq in advanced..Really need help

  2. #2
    up to my .as in code Chris_Seahorn's Avatar
    Join Date
    Dec 2004
    Posts
    4,389
    You will have to set your folder options to allow viewing hidden files and directories but can locate where to find your DB using:

    trace(dbFile.nativePath);

  3. #3
    Senior Member
    Join Date
    Mar 2005
    Posts
    154
    Thanks for the reply guys

    I get manage to locate my db now..do it as ur suggest huh copy dc ti worddb file and place it in document directory

    tq again

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center