On 11 Jul 2009, at 10:27pm, Derek Developer wrote: > When I launch my app the SQLite database and reads a portion of the > contents (about 30MB of a 100MB database). > On first launch it can take 50secs to load, yet subsequent loads are > as fast as 10sec. What is happening under the hood?
I can't think of any reason it should take 50 seconds unless your application is intentionally reading a lot of records into memory or something like that. Since you're posting, you presumably know that it isn't doing anything like that, and are puzzled about why it's taking that long. Make a copy of the database file and delete all records from it. Use that one with your application. That way it can't be spending all that time reading records into memory. Does it still take that 50 seconds to launch ? The other question is whether you're running under some versions of Windows. There was some sort of weird aggressive caching interaction under some versions of Windows. I don't know if it's fixed now, or whether it still happens, and I can't remember where I read about it. The good news was that it was related to the file extension: changing the extension from '.db' to '.sqlite' made the problem go away. I'd love to post a URL for a better explanation but I can't find one. Does anyone else remember this thing ? Simon. _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users