Hi all, I just made my first steps into sqlite (3.3.4).
I created a small table, filled it with two rows of data and timed a select. Those were the results: % time {db eval {select * from cust_persons where first_name='Ulrich'}} 1000 75.498 microseconds per iteration % time {db eval {select * from cust_persons where first_name='Ulrich'}} 10000 51.6179 microseconds per iteration % time {db eval {select * from cust_persons where first_name='Ulrich'}} 100 309.95 microseconds per iteration % time {db eval {select * from cust_persons where first_name='Ulrich'}} 10 66.8 microseconds per iteration Do you notice the 309.95 microseconds? I first blamed it on a busy harddisk and repeated all four commands several times. The results vary slightly but keep in the above picture. Where do those 309.95 microseconds come from? What's the difference between running a query 100 times or 10000 times? Should I avoid running a select exactly 100 times for some obscure reason? Maybe someone here knows the secret. Kind regards Ulrich