1 Reply Latest reply on Oct 2, 2009 9:32 AM by adobe_paul

    Adobe AIR SQL performance while inserting row

    verseview Level 1

      I am working on an application that has 1000s of rows of data to be inserted to a table in a db. I am doing it in an async method. A new SQLStatement connection is open in the beginning. Then each time the SQL parameter gets updated and the execute() function is called. When the row is written to disk and the sucess event is generated, the parameter is updated again and the execute() is called again until all rows are stored in the DB.

       

      This is very slow performance, each transaction takes about 50ms to 300ms depending on if the disk is free.

       

      How can I make this more efficient? Is there a way to create the whole table in memory and then dump it to a file? Can I execute few transations together? The bottle neck is the access to the file system.

       

      This application is to index a huge text file. Each word of the text file is stored in a row along with some index numbers that track the word in the text file.

       

      Thank you for your help

      Binu Joseph

      www.verseview.info

      verseview@yahoo.com