[For Brian P.]
Sorry if I am posting out of my original thread but I didn't still perfectly understand how the forums work... if an updated thread goes on the topm etc. ..
Hello again :) Adding keys didn't give any performance benefit as moving to MyIsam did... so well, knowing that Databases and SQL are very obscure matters, here are some queries (I modified the code so that it outputs the queries it generates, before actually executing them, with some timing info too)
(ps: What does the double fetch time in MySql Query Broswer mean?)
SELECT COUNT(*) FROM anagrafiche WHERE ((operatore='' OR operatore is null) AND ( data_contatto<'2007-09-10' OR data_contatto is null)) AND (provincia="PA")
*** 1 row fetched in 0,0012s (3,5567s) ***
SELECT id,telefono,cellulare,nome,cognome,citta,provincia,indirizzo,cap,note,data_richiamo,note_richiamo FROM anagrafiche WHERE ((operatore='' OR operatore is null) AND ( data_contatto<'2007-09-10' OR data_contatto is null)) AND (provincia="PA") LIMIT 131135,1
*** 1 row fetched in 0,0028s (3,7639s) ***
All the slow queries are like the aforementioned couple.
Thanks again,
- andrea