On 9 Sep 2010, at 4:55am, Hemant Shah wrote:

> The other process wakes up every 60 seconds and deletes all row whose 
> timestamp columns is less then (current timestamp - 60). The timestamp is 
> number of seconds since epoch.

Do you do this using a single DELETE FROM command ?  Do you have an index on 
the timestamp column so it can find the appropriate rows quickly and easily ?

> The first process is constantly inserting rows into the database, so the 
> other process cannot delete any rows.

I would probably merge the processes.  Have the one that does the inserting 
issue the DELETE FROM command.  So it could do a DELETE after every INSERT.  Or 
better still, after every 100 INSERTs or something.

Simon.
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to