You go from 2 minutes to 30 minutes just based on clock speed. I would imagine you don't have much disk cache on the ARM device, so every time you read the database it has to hit the file system....ouch....
Did you benchmark your PC system without using a cached database? Just edit the database to force a re-read. I think you're probably testing your PC side with a cached databse which may explain a lot of the remaining 6X performance difference. Michael D. Black Senior Scientist NG Information Systems Advanced Analytics Directorate ________________________________________ From: [email protected] [[email protected]] on behalf of Gigin Jose [[email protected]] Sent: Tuesday, March 08, 2011 8:52 AM To: [email protected] Subject: EXT :[sqlite] sqlite DB extraction Hi, I am working on embedded arm linux.I am trying to extract records form a local database of sqlite using QT Application. My local database is of size 2.6MB and contains almost 1.2 lakh records , each record has three fields (ID, name, address). I am trying to extract all the records from database and store it in a single QByteArray (equivalent to char array ) variable. But the extraction procedure is very slow. It took me 3 hours to extract the entire data (on ARM9 device with 200MHz clock). While the same code on a Intel Core 2 duo 2.93GHz PC with linux took less than two minutes for the entire extraction. On the ARM device, I use NAND flash as the storage medium and yaffs2 as the file system. The code segment is given below: QString str="select * from table_user20"; query_model.setQuery(str); i=0; while(query_model.record(i).value("Id").toByteArray()!="") { data+=query_model.record(i).value("Id").toByteArray(); data=data+unit_sp; data +=query_model.record(i).value("Name").toByteArray(); data=data+unit_sp; data +=query_model.record(i).value("Address").toByteArray(); data +=record_sp; i++; } Is the system supposed to take this amount of time on a ARM base embedded device ? Is there any better way to extract data ? With RegardsGIGIN _______________________________________________ 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

